Links

Lists

Latest Updates

Ruby On Rails List
Python list
Advanced Java
The JavaScript List
Apache Users
Full Disclosure
Linux Security

Search the archives!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Javascript] Why is script line needed to change values


  • From: twlewis at SoftHome.net (twlewis@xxxxxxxxxxxx)
  • Subject: [Javascript] Why is script line needed to change values
  • Date: Mon May 21 15:47:20 2007

I apologize, because this is a little off-topic from javascript.  I had
completed my javascript, which loads data to a textarea.  It would not
load the textarea.  I have a VBScript version that worked.  After much
careful elimination of code on the VBScript version, I found that the line
that was making the onclick work was the script statement.  I created a
chopped down version to test and play with.  In the script below, if I
remove the line
<script Language="VBScript" src="none"></script>,
the onclick no longer works.  I can paste it back in, and the button
changes as it is supposed to.  Can someone please explain this to me?
Thank you for your patience and explanation.
Tim


<html>
<head>
<script Language="VBScript" src="none"></script>

</head><body>
<form id=myform>
<input type="button" value="Click me!" id=Button1 name="button">

<input type="button" value="Change button 1 to monkey"
onclick="Button1.Value='monkey'">

</form>
</body>
</html>