JavaScript Tutorial
I dedicate this Tutorial to you, dear friends, all around the world. by_ Shahin Noursalehi
<Prev.  (Main)  Next>

JSrcipt Tutorial
Lesson: 2

Sample Description:
Text Attachment!

User Level:
1.New
2.Casual
3.Accomplished
4.Expert




About Lesson 2:

The Text Attachment! sample is as same as lesson 1. When you are clicking on the button the text box's value will attach to the string 'New'.
Pay attention to the HTML source codes that are provided here.
And again, Pay attention to the 'onclick' event.








Test the sample!

  
<HTML>
<HEAD>
<TITLE>
</TITLE>
</HEAD>
<SCRIPT language=javascript>
<!--
var aa
function salaam1(){
aa=text2.value;
aa=aa+'new';
text2.value=aa;
}
//-->
</SCRIPT>
<BODY bgcolor=white>
<INPUT id=button2 name=button2
type=button
LANGUAGE=javascript
onclick="return salaam1()">
<INPUT id=text2 name=text2>
</BODY>
</HTML>




© 2000 by MixofTix Developers Network. All rights reserved.