<script type='text/javascript'> $(window).load(function(){ $("body").click(function(){ var s = window.getSelection(); s.modify('extend','backward','word'); var b = s.toString(); s.modify('extend','forward','word'); var a = s.toString(); s.modify('move','forward','character'); var variablej=b+a; //variablej is Jquery Variable //how to pass a Jquery variable to php variable <?php $variablephp = "<script>document.write(variablej)</script>" ?> //variablephp is php variable <?php $result = mysql_query("SELECT * FROM translate where English='$variablephp'"); ?> </script>
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)