javascript & php
| From: | Roman Duriancik | Date: | Mon, 28 Jul 2003 10:48:04 +0000 |
| Subject: | javascript & php | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-157155@lists.php.net to get a copy of this message | ||
I have problem with variables in javascript and php.
I have code in php and in this code I insert some values from javascript.:
$color = "<script><!--
document.write(screen.colorDepth)
//-->
</script>";
when I write command echo $color - result is correct.
but when i need insert or select some values from database with this value ($color) result is not correct
this is my code :
$query = mysql_query("select id from color where color = '$color' ");
$a = mysql_num_rows($query);
result is 0.
but in my database i have record where is value like value $color.
roman