Programming Forums

Programming Forums (http://www.programmingforums.org/forumindex.php)
-   JavaScript and Client-Side Browser Scripting (http://www.programmingforums.org/forum23.html)
-   -   can't seem to get my app working on the web (http://www.programmingforums.org/showthread.php?t=5652)

glevine Aug 30th, 2005 12:24 PM

can't seem to get my app working on the web
 
I have 'somewhat' successfully written an app using html, javascript, and xmlhttprequest that grabs data from a js file residing on another website and displays the data found in that file. I say 'somewhat' because I can run the app locally, but it fails when I attempt to run it from the web. After storing the file in a directory on my webserver I can't seem to get the page to work. I can input data, but I can't get any output. Using Firefox, I get absolutely nothing. Using IE, I get an error. That error claims to be for the line...

:

http.open("GET", url + escape(file), true);

'http' is the value that is returned by 'new XMLHttpRequest();' and 'file' is the string representing the js file that needs to be opened. 'url' is the string that represents the URL of the file location without the filename concatenated. I was hoping someone might know a reason why the open function wouldn't work in my case. If you need more info please ask. Thanks.

Arevos Aug 30th, 2005 1:06 PM

Sounds to me like it might be a problem with "url + escape(file)". Have you tried putting in a debug line? Something like "document.write(url + escape(file))"?

glevine Aug 30th, 2005 2:17 PM

That doesn't seem to be the problem. The url, including filename, is correct when outputted. You may know something that I don't, but I don't see how I could connect successfully to the js file locally if the url wasn't correct. This app doesn't work only when trying to run it from the web server.

glevine Aug 30th, 2005 2:51 PM

Is it possible that it could be a security issue? I can't see any evidence of that and changing file permissions doesn't change anything, but maybe someone knows more about this than me.


All times are GMT -5. The time now is 5:30 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC