Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Aug 30th, 2005, 12:24 PM   #1
glevine
Newbie
 
Join Date: Jun 2005
Posts: 22
Rep Power: 0 glevine is on a distinguished road
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.
glevine is offline   Reply With Quote
Old Aug 30th, 2005, 1:06 PM   #2
Arevos
Programming Guru
 
Arevos's Avatar
 
Join Date: Aug 2005
Location: England
Posts: 1,499
Rep Power: 4 Arevos is on a distinguished road
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))"?
Arevos is offline   Reply With Quote
Old Aug 30th, 2005, 2:17 PM   #3
glevine
Newbie
 
Join Date: Jun 2005
Posts: 22
Rep Power: 0 glevine is on a distinguished road
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 is offline   Reply With Quote
Old Aug 30th, 2005, 2:51 PM   #4
glevine
Newbie
 
Join Date: Jun 2005
Posts: 22
Rep Power: 0 glevine is on a distinguished road
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.
glevine is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 1:58 AM.

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