View Single Post
  #17 (permalink)  
Old 03-05-10, 01:05 AM
argonet702 argonet702 is offline
New Member
 
Join Date: Mar 2010
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
I am sorry the last example doesn't work,

I am sorry the last example doesn't work, if you want to pass a variable from javascript to PHP, you need to write everything on PHP, then pass the javascript variable with >> window.location.href , then get it with PHP.

I am sorry the last example doesn't work,

<?php

if($_GET['lemonk_include']=="0"){
echo ("<script type='text/javascript' src='../js/jquery-1.3.2.js'></script>");
}
else{

echo ("<script language='javascript' type='text/javascript'>");
echo ("if(typeof jQuery != 'function'){window.location.href = location.href + '&lemonk_include=' + '0';}else{}");
echo ("</script");


}
?>


This is also for detecting if JQuery was detected, if not, it will be included once.
Reply With Quote