Possible Duplicate:
Get variable from PHP to JavaScript
I am working in wikipedia api, how to search query with two words like "new york", as it is returning no image when using two words ?
Possible Duplicate:
Get variable from PHP to JavaScript
I am working in wikipedia api, how to search query with two words like "new york", as it is returning no image when using two words ?
$.getJSON("http://en.wikipedia.org/w/api.php?action=mobileview&format=json&page=<?php echo $query ?>&redirect=no§ions=0&prop=text§ionprop=toclevel%7Clevel%7Cline%7Cnumber%7Cindex%7Cfromtitle%7Canchor&callback=?", function(json) {
That is use <?php echo $query ?>
should work....