• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

VBSCRIPT, A HREF, and JavaScript


Bow Down to the King
Political User
Okay, here's the deal.

I wrote a VBSCRIPT to save the contents of an TEXTAREA box to a file on my HDD. I call this script using the onClick="setFile('location')" function inside an A HREF statement. The VBSCRIPT works perfectly and saves the input to a file stored on my HDD.

The problem I am having is that I am trying to prevent MSIE from launching. I tried using href="javascript:void(0)", but the browser still opens with a "the page cannot be displayed" error.

Here's the A HREF:

<a onClick="setFile('c:\\windows\\quicknotes.txt')" href="javascript:void(0)">save</a>

(there are no spaces between JAVA and SCRIPT, the bold print just makes it appear so).

Any help would be appreciated, thank you in advance.


Bow Down to the King
Political User
Originally posted by Zedric
There IS a space (check the HTML code...), I hope you don't have that in your code.
I said, there is not a space. Believe me, there is NOT a space in the actual code. Displaying the code using the forum's BOLD code makes it appear so. Once again, there is NOT a space between JAVA and SCRIPT. Thanks for trying though. =)

Members online

Latest posts

Latest profile posts

Electronic Punk wrote on Perris Calderon's profile.
All good still mate?
Hello, is there anybody in there? Just nod if you can hear me ...
What a long strange trip it's been. =)

Forum statistics

Latest member