Weird Thoughts From Eric's Head

Tags - Categories : All | AJAX | BUSINESS | PERSONAL | PROGRAMMING | BOOK REVIEW

Download Firebug and view your XMLHttpRequests

I tell people to always download Firefox and install the Firebug extension. I normally get asked how do I see the XMLHttpRequests with it. Well I am tired of repeating myelf on forums so I thought I would post it here so I can point people to it!

If you have never used Firebug, it is going to change the way you develop JavaScript! The feature I want you to see is the allowing Firebug to show the XMLHttpRequest. By default it is not set, so we need to enable it. Rather easy, under options menu select ShowXMLHttpRequests. I hightlighted it in the screenshot below.

Firebug options

Now after you do this, you will be able to see the requests made. So I thought I would search my name on Google Suggest. Below shows you all of the requests made until my name shows up.

Google Suggest with requests

Firebug also allows us to look at the request in more detail. You can do that by clicking on the url in the Firebug window. It opens up the request details. (If you used post, it would show post details.)

Closer look at the request

If you would click on the line number, it would take you to that line number in the source code. Rather cool in my eyes. There are tons of features in Firebug, spend some time and play with it! Also I hope you did not miss my article on the IE Developer Toolbar! If you did go read it. One thing I wish I could do with Firebug is undock it like the IE Developer Toolbar. Sometimes Firebug takes up way too much space for what you are after, but I could not live without this tool. Tomorrow I will have an article on Drip.



Eric Pascarello
Coauthor of Ajax In Action
Moderator of HTML/JavaScript at www.JavaRanch.com
Author of: JavaScript: Your Visual Blueprint for building Dynamic Web Pages


Everyday I learn about a cool new feature in Firebug that I didn't know about. Thanks for this one. If I would have known about it yesterday, it would have saved me 4 hours.
Nice tip Eric.
Thanks
Balaji
Well, I have a weird one. On initial page interaction, my http requests act fine. Then, I go to the next page and then click back. Now, all ajax requests get a resource unavailable message in the safari activity window. The ajax call seems to be tried, but the responseText and responseXML is null. Anyone ever run into that?


Add a comment

Title
Body
HTML : b, i, blockquote, br, p, pre, a href="", ul, ol, li
Math Quiz 5 + 5 = (Helps stop blog spam)
Name
E-mail address
Website
Remember me Yes  No 

E-mail addresses are not publicly displayed, so please only leave your e-mail address if you would like to be notified when new comments are added to this blog entry (you can opt-out later).

TrackBack to http://radio.javaranch.com/pascarello/addTrackBack.action?entry=1158158516682