|
-
Feb 12th, 2003, 01:40 AM
#1
Javascript problems
Put very simply, the problem is that javascript scripts work only if I'm viewing a website (or any page from a server). It won't work if I'm viewing a page locally.
Does anyone have any idea about this?
-
Feb 12th, 2003, 04:41 AM
#2
Fanatic Member
That's wierd!
Have you checked the HTML path to the .JS or .CLASS files in your index.htm(L) ?
It could be still looking for it via the web, which usually wouldn't really be a problem...
Some HTML pages check which page the file was called from (HTTP_Referer), and if you're calling it locally, the HTML would fail automatically... and not due to an error.
Regards,
Paul.
-
Feb 12th, 2003, 07:03 AM
#3
Frenzied Member
You sure you're not load an external JS file something like "/files/file.js" so it's looking in the wrong place?
EDIT: Oops sorry that's what VisionIT said, sorry
-
Feb 12th, 2003, 10:30 AM
#4
No, what I mean is, any html file... the javascript part just won't work. Even something as simple as:
Code:
<html>
<head>
<title>blah</title>
</head>
<body onLoad="javascript:alert('hello');">
adlkfjalfjas;lfjaflj
</body>
</html>
Javascript just doesn't work locally at all.
Now what are these .js and .class files you refer to? There are no external files involved here.
-
Feb 12th, 2003, 10:31 AM
#5
Could it be a DLL problem? I don't know much about them.
-
Feb 12th, 2003, 10:40 AM
#6
Hyperactive Member
there isn't suppose to be a space between "java script". Change that and it should work
-
Feb 12th, 2003, 11:14 AM
#7
Originally posted by OrdinaryGuy
there isn't suppose to be a space between "java script". Change that and it should work
The space gets put in there itself when I'm posting that code.
Yash... it's not a problem of coding. I'm talking about any javascript. ANY javascript in ANY html file, it won't execute locally.
-
Feb 12th, 2003, 11:28 AM
#8
Black Cat
Using IE, right? Check your security setting for Trusted Sites or Local Intranet or whatever zone IE puts the local filesystem into for disabled scripting.
Josh
Get these: Mozilla Opera OpenBSD
I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.
-
Feb 13th, 2003, 05:27 PM
#9
Fanatic Member
Quickest option...
Download the new JavaSDK from MS.
Regards,
Paul.
-
Feb 14th, 2003, 11:07 AM
#10
Black Cat
Mendhak, can you run JScript thru WSH (or ASP if you have IIS installed)?
Josh
Get these: Mozilla Opera OpenBSD
I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.
-
Feb 14th, 2003, 08:49 PM
#11
Originally posted by JoshT
Mendhak, can you run JScript thru WSH (or ASP if you have IIS installed)?
eh? Didn't understand that...
I can run Javascript only when viewing a web page from the server. So this means instead of C:/inetpub/wwwroot/index.html, I have to do http://localhost/index.html for the javascript to work... I have PWS.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|