943,912 Members | Top Members by Rank

Ad:
Mar 14th, 2006
0

Please help!! i am so desperate!

Expand Post »
hi there,
i'm doing a basic computer science homework and i cannot figure out how to run the javascript on the browser...
so i write a program on microsoft word and save as "java.html" under html document, then what do i do to display the contents on the browser???
any help would be greatly appreciated!!!
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
jasmineleo is offline Offline
2 posts
since Mar 2006
Mar 14th, 2006
0

Re: Please help!! i am so desperate!

I bet the filename is actually named: java.html.doc, unless you have specifically gone into windows and told it to show you filename extentions. you can open up internet explorer, and go to file open, and it might open it that way, but being it's probably in word format, it might get really upset. If you want to fix it, you can go to my computer, then tools, and folder options. Then click on the view tab, and in the listbox find hidden files and folders, and put the dot in show hidden files and folders, Then hit ok. You should be able to rename the file properly now.
Team Colleague
Reputation Points: 361
Solved Threads: 214
Taboo Programmer
Comatose is offline Offline
2,413 posts
since Dec 2004
Mar 14th, 2006
0

Re: Please help!! i am so desperate!

And if this isn't the case, and the file really is an HTML file with a ".html" extension, simply double-clicking it should open it in your default browser.

If not, then open the browser, and drag the file into the browser.
Team Colleague
Reputation Points: 227
Solved Threads: 37
Made Her Cry
tgreer is offline Offline
1,697 posts
since Dec 2004
Mar 14th, 2006
0

Re: Please help!! i am so desperate!

thank you so much for your help...but i still don't understand??
all i'm trying to do is open the document file through a web browser but when i open the internet explorer, and go to file, open, and open the document file, it shows exactly what i wrote in my document file... since it's a javascript program, shouldn't it only show hello world! if i wrote:

<html>
<body>

<script type="text/javascript">
document.write("Hello World!")
</script>

</body>
</html>
Reputation Points: 10
Solved Threads: 0
Newbie Poster
jasmineleo is offline Offline
2 posts
since Mar 2006
Mar 14th, 2006
0

Re: Please help!! i am so desperate!

If you're using Internet Explorer, you're probably getting a security alert, since IE won't run JavaScript on files loaded locally.

However, from your description, I would say Comatose is probably closest to the truth: your browser is treating it like it's a text file, not an HTML file.

Are you sure the file has .html as the extension, and not .doc or .txt?
Team Colleague
Reputation Points: 227
Solved Threads: 37
Made Her Cry
tgreer is offline Offline
1,697 posts
since Dec 2004
Mar 14th, 2006
0

Re: Please help!! i am so desperate!

where is the file saved on your hard-drive? Right click on the file, go to properties, and where does "location" say it's it?

Another alternative, is to simply unzip this attachment, and put the quickren.exe file in the c:\windows folder. Then double click on quickren.exe. Now, right click on your html file, and choose quickren. Then, make sure that the filename is java.html, and not java.html.doc, or java.html.txt
Attached Files
File Type: zip QuickRen.zip (6.2 KB, 12 views)
Team Colleague
Reputation Points: 361
Solved Threads: 214
Taboo Programmer
Comatose is offline Offline
2,413 posts
since Dec 2004
Mar 15th, 2006
0

Re: Please help!! i am so desperate!

Or go to start -> programs -> accessories -> notepad
Paste in your html code.
Save as java.html - remember to select 'all files and folders' in the file type below the filename box
Open in your browser.

You could also consider downloading html kit
http://www.chami.com/html-kit/
Reputation Points: 54
Solved Threads: 20
Master Poster
DaveSW is offline Offline
765 posts
since Jul 2004
Mar 16th, 2006
0

Re: Please help!! i am so desperate!

yea this is the best answer
why u r using word, just go to notepad and write ur code there.
Save it as *.htm.
This is the easiet method
Reputation Points: 10
Solved Threads: 1
Junior Poster in Training
web_developer is offline Offline
84 posts
since Mar 2006

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in JavaScript / DHTML / AJAX Forum Timeline: How to close IE without a user dialog box?
Next Thread in JavaScript / DHTML / AJAX Forum Timeline: Runtime Error Help PLEASE





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC