If you already knows this Pls forgive me.
I have tried you code there it is working fine.
do you know w3schools.
Please go to the below link and paste your code in the left hand side and click the "Edit the text and click me" button
http://www.w3schools.com/js/tryit.asp?filename=tryjs_browser
<html>
<body>
<script type="text/javascript">
function object(string){
this.string = string;
this.method1 = method1;
this.method2 = method2;
this.method3 = method3;
}
function method1(){
alert ("method1");
this.method2();
}
function method2(){
alert ("method2");
this.method3();
}
function method3(){
alert ("method3");
alert(this.string);
}
myObject = new object("text");
myObject.method1();
</script>
</body>
</html>
If this not helps you I am very sorry . your code is working fine in my system
Regards
Jegan
Enter your message below
Sign in or Join us (it's free).