Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

php & javascript variables

Status
Not open for further replies.

HUSS

Technical User
Dec 10, 2001
12
0
0
US
hi, I want to assign the value of a javascript's variable to a php variable.How it is possible in javascript function??
I tried it in php file ,but unable to do that .plz help me & correct tje code .thanx in advance
the code is


<!doctype html public &quot;-//W3C//DTD HTML 4.0 //EN&quot;>
<html>
<head>
<title>Title here!</title>

</head>
<body>

<form name=&quot;contest&quot; method=&quot;post&quot;>
<input type=&quot;button&quot; ONCLICK=&quot;mush()&quot; value=&quot;click me&quot;>
<input type=&quot;textarea&quot; name=&quot;area&quot; >
</textarea>
</form>
<?php

echo &quot;
<script language='javascript' >

function mush() { \n
jojo=document.contest.area; &quot;;
$applicant=&quot;jojo&quot;;
echo &quot; alert(' Hello $applicant ');

}

</script>&quot;;





?>

</BODY>
</html>
 
see thread434-128374
are you in the same class ;) ??
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top