Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Accessing browser events in chrome extension - DOM events in chrome extension

I am writing a chrome plugin in which I would like to receive events such as "load", "unload" of window and page. However, I'm not getting any concrete clue to start with.

Can anyone tell me how to capture DOM event in plugin?

Does Chrome support this feature?

Thank you.

like image 565
Abhay Avatar asked May 18 '10 03:05

Abhay


1 Answers

You would need Content Scripts and you just add normal browser events to the JavaScript you inject as you stated in your question. Every page will have that content script and it will listen on those events.

like image 196
Mohamed Mansour Avatar answered Oct 05 '22 19:10

Mohamed Mansour