[eluser]Andy UK[/eluser]
Hi guys,
for my google maps mashup i ended up with a lot of code in my header and decided to move it to a separate .js file in my scripts folder.
Code:
<?php if(isset($gmap_multiple_markers)) {
echo "include google maps here with key between script tags...";
echo "Include map_search.js javascript file here between script tags...";
}
?>
All well and good, but there's a part of that map_search.js file that needs to read in other files and i need to give it the current site url which changes depending on the language be used.
The question therefore is: How can i pass a variable or a constant to the included javascript file so that the site url is included in the path?
Thanks for your help!
Andy.