I would l开发者_高级运维ike to know how to retrieve the value of a textarea box that was initially hidden but when a checkbox is ticked it reveals the textbox for input. I have posted my code here:
http://jsfiddle.net/RF5PK/
many thanks
Generally, using val()
:
$('textarea[name="setmessage"]').val();
Here's a demo.
Although, from the code sample, I get the impression there's more to this question than meets the eye!
Try this
$('textarea[name="setmessage"]').val();
http://jsfiddle.net/RF5PK/4/ see this i have only used needed jquery for your question. And I have added contactmessage class to your text area.
精彩评论