jquery textarea how can I get the value

I have seen a lot of people mention this, but it just isn't working.  How can I get the value of what is typed into a text area in jquery?

$("#ReportThisComments").val();
This does not work
jackjohnson44Asked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
Steve KrileConnect With a Mentor Commented:
Here is a full working model
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
		<title>Untitled Document</title>
		<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>


	</head>
	<body>
		<textarea id="ReportThisComments"></textarea>
		<button id="clicker">Click to see textarea text</button>
	</body>

		<script type="text/javascript">

			$(function(){
				$("#clicker").click(function(){
					//alert the textarea value
					alert($("#ReportThisComments").val());
				});
			})
		</script>

</html>

Open in new window

0
 
leakim971PluritechnicianCommented:
Hello jackjohnson44,

$("#ReportThisComments").val();

do you have :



# is for id

Regards.
0
All Courses

From novice to tech pro — start learning today.