SitePoint Sponsor |
|
User Tag List
Results 1 to 3 of 3
Thread: ajax.js from Book example
-
Sep 15, 2006, 10:18 #1
- Join Date
- Sep 2006
- Posts
- 6
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
ajax.js from Book example
I have the book Build Your Own Ajax Web Applications
I have tried making the default Ajax class file (which I named main.js)
and I get no output and no errors
I am not sure where I went wrong
I tested with IE6 and Firefox latest.
Here is the code:
http://sial.org/pbot/19704
fakeserver.php gives me the expected output when visited directly
here is my index.html:
Code:<html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>A Simple AJAX Test</title> <script type="text/javascript" src="js/main.js"></script> <script type="text/javascript"> var hand = function(str) { alert(str); } var ajax = new Ajax(); ajax.doGet('/fakeserver.php', hand, 'text'); </script> </head> <body> </body> </html>
-
Sep 15, 2006, 13:22 #2
- Join Date
- May 2006
- Location
- Ventura, CA
- Posts
- 2,750
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Code:this.mimeType = null; } this.init = function() {
-
Sep 15, 2006, 14:11 #3
- Join Date
- Sep 2006
- Posts
- 6
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
well I didn't find the problem .. but thanks .. at least now I know about
Javascript console.
Bookmarks