I need to make an easy JavaScript function that will out put some html to screen by calling a PHP file on a different server.
Something like this:
[JavaScript]
contents = http://www.example.com?clientID=1
print to screen contents;
[/JavaScript]
The PHP file would look up the information based on that clientID that is passed from the javascript call and then return the correct string, in this case an image.
I want to use JavaScript because I want this to be usable by everyone not just people that can add PHP to their websites, for example a basic Wordpress site wouldn't be able to include a PHP file from an outside server without an extra plugin to include the php in the page etc.
Like how you can include twitter & facebook code in your site to show your news feed but I want the server side to be PHP.