Solved

document.formname.textarea.value output

Posted on 2003-12-08
3
490 Views
Last Modified: 2012-05-04
I need to udate a hidden field in another form from a textarea on the same page, when i click refresh the data that comes back is always undefined.
this is basicly what I have sofar...
<script>
<!--
function getplans(id)
{
document.hiddenform.comments.value =      document.insert_asset.comments.value;
}
//-->
</script>

<form name="insert_asset">
<textarea name="comments" cols="20" rows="3" wrap="virtual"><%=Request("comments")%></textarea>
<input type="button" onclick getplans("123")>
</form>
<form name="hiddenform">
<input type="hidden" name="comments">
</form>

how do I get the comments input in hiddenform the same as the comments textarea  in insert_asset? ( I will then be using the hiddenform to post the info to another page.
0
Comment
Question by:Pyro-San
  • 2
3 Comments
 
LVL 11

Accepted Solution

by:
Zontar earned 50 total points
ID: 9902674
<script type="text/javascript">
<!--
function getplans(){ document.hiddenform.comments.value = document.insert_asset.comments.value; }
//-->
</script>

<form name="insert_asset">
<textarea name="comments" cols="20" rows="3" wrap="virtual"><%=Request("comments")%></textarea>
<input type="button" onclick="getplans();">
</form>
<form name="hiddenform">
<input type="hidden" name="comments">
</form>
0
 

Author Comment

by:Pyro-San
ID: 9908378
:) sorry silly me cant see past my nose, I figured the problem out and it is not with the code I pasted, it is with a portion of the code I left out on my page. that code that I posted works, thanks anyhow Zontar
0
 
LVL 11

Expert Comment

by:Zontar
ID: 9909186
Fair 'nuff. Ta for the points.

If I had ten cents for every dumb typo or copy/paste error I've made that caused me fits, I'd be nearly as rich as Bill Gates. ;)
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Close "X" button on window popup in Firefox 7 37
Accessing data in JSON response.d multiple objects 2 60
SharePoint 2013 List with Ratings 6 37
Message not shown 5 33
Introduction HTML checkboxes provide the perfect way for a web developer to receive client input when the client's options might be none, one or many.  But the PHP code for processing the checkboxes can be confusing at first.  What if a checkbox is…
Having worked on larger scale sites, we found out that you are bound to look at more scalable solutions to integrating widgets, code snippets or complete applications and mesh them into functional sites, in any given composition. To share some of…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

867 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now