Thank You for your attention but i'm new to javascript and maybe i
don't understand sth.

> > var XMLHttpRequestWrapper = function(activeXObject){
> >    console.log("xhr!!!!!!!!!!!");
> >    new XMLHttpRequest();
> > }
>
> This code is incomplete and won't work properly because the wrapper does not
> have the open(), send() and other methods. But I suppose you already know
> that and this is just a sample code to demonstrate what you are trying to
> do.

I now it's incomplete but I want to do a simple thing here for the
beggining- I want to console.log("xhr"); on every xmlhttprequest on
page (even without finishing this request)

> > var _XMLHttpRequest = XMLHttpRequest;
> > window.XMLHttpRequest = function()
> >    {
> >        return new XMLHttpRequestWrapper();
> >    };
> > -------------------------------
> > it only fires on my own xhrs not on those from website.
>
> Chrome extension runs in a sandboxed environment, which means that if you
> execute the wrapper in the sandbox only XHR calls made inside the sandbox
> will be tracked. That's the behavior you are seeing.
>
> If you want to listen for XHR calls made by the page, you need to inject a
> script at the page and then use a "Content Script" to communicate with it:
>
> http://code.google.com/chrome/extensions/content_scripts.html#host-pa...

I've red this but they communicate with this page (http://foo.com/
example.html) involving in it's code (maybe I misunderstood). And how
can I communicate with all pages outside sandbox only with content
sript and background page? Firebug lite for chrome does that for every
page. It monitors xhrs on everywhere! I still don't understand how.
Please help me.

Luke

-- 
You received this message because you are subscribed to the Google Groups 
"Firebug" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/firebug?hl=en.

Reply via email to