How can we assign an object in Java Script??
For Example:-
-----------
If i create an object "obj1"
var obj1 = Object();
obj1.name = "hari";
and if i want to assign it to two objects "obj2" and "obj3"
with different names...
obj1.name = "gopi"
obj2 = new Object(obj1);
obj1.name = "raghu"
obj3 = new Object(obj1)
Now ob2.name become to "raghu" from "gopi". WHY?
how to solve the above problem?
Answer Posted / rajesh
I maynot give the exact reason..but root cause may be
because of...
As you know the javascript is just parsed from top to
bottom. It won;t execute as long as you run the app.
While parsing it just holds the reference and checks for
syntactical errors.
Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
What is json? : asp.net ajax
What is the difference between synchronous and asynchronous requests?
Describe the animation extender control and the method by which this control is utilized?
What will happen with click of browser "back" button among asynchronous requests?
What's the difference in HTML AJAX, ASP.Net AJAX?
What are the important methods of xmlhttprequest?
We used asynchronous server communication for a long time, what new thing is ajax bringing?
In what way are proxyless calls different than the proxied calls in ajax?
How to control how long an ajax request may last?
What are the new features of asp.net ajax 4.0? : asp.net ajax
Do we have to use http get/post for the ajax calls?
How can you debug asp.net ajax applications?
Can ajax be implemented in browsers that do not support the xmlhttprequest object?
How was ajax killed?
What are the types of open() method used for xmlhttprequest?