hello every body,
i have prob. of asigning javascript variable to php variable in side javascript function,
ie, i have a javascript variable like JavaScriptVar,
then how can i asign this variable to php variable, $phpvariable
like;
$phpvariable=JavascriptVar;
please give me suggestion,
regards
murali
how can i asign javascript variable to a php variable
Moderator: General Moderators
-
B.Murali Krishna
- Forum Commoner
- Posts: 28
- Joined: Fri May 12, 2006 2:05 am
- Location: Hyderabad,India
- Contact:
- xpgeek
- Forum Contributor
- Posts: 146
- Joined: Mon May 22, 2006 1:45 am
- Location: Kyiv, Ukraine
- Contact:
You don't have to want this.
PHP script get data from EGPCS variables, e.g.(GET/POST/...).
You can put js variable into url or into hidden fields of form.
PHP script get data from EGPCS variables, e.g.(GET/POST/...).
You can put js variable into url or into hidden fields of form.
Code: Select all
<script>
//......
var url = "http://somehost.com/myscript.php?myphpvar="+myjsvar;
window.location=url;
</script>-
B.Murali Krishna
- Forum Commoner
- Posts: 28
- Joined: Fri May 12, 2006 2:05 am
- Location: Hyderabad,India
- Contact:
xpgeek wrote:You don't have to want this.
PHP script get data from EGPCS variables, e.g.(GET/POST/...).
You can put js variable into url or into hidden fields of form.Code: Select all
<script> //...... var url = "http://somehost.com/myscript.php?myphpvar="+myjsvar; window.location=url; </script>
No, i dont mean that, i need to asign the variable there only, inside the function, for furthur, application