View Single Post
Join Date: May 2005
Posts: 182
Reputation: alpha_foobar is an unknown quantity at this point 
Solved Threads: 3
alpha_foobar's Avatar
alpha_foobar alpha_foobar is offline Offline
Junior Poster

Re: Urgent.....Dynamic Changes....

 
0
  #10
May 4th, 2005
Well its easy now...

JavaScript / DHTML / AJAX Syntax (Toggle Plain Text)
  1.  
  2. elementOfName(document, "pName").value = elementOfName(obj.parentNode, "prname").value;

notice that you search the document node for the node with the name "pName", so this name needs to be unique.

A better way, would be to use the getElementyId function.. but this needs a unique id. i.e.

you'll need to this:
JavaScript / DHTML / AJAX Syntax (Toggle Plain Text)
  1.  
  2. <input type="hidden" name='pName' id="pName">

then you can do this:

JavaScript / DHTML / AJAX Syntax (Toggle Plain Text)
  1.  
  2. document.getElementById("pName").value = elementOfName(obj.parentNode, "prname").value;
Reply With Quote