Hi I need to get this done if its possible. Is it possible to have this code <?php include(www.websites.com/code.php); ?> My purpose is i wanted to put a code on many websites and when i update that code all of the websites i insert the code will be updated as well. Please let me know how can i do this... thanks in advance...
If you want to do that you will need to output the code without it going through the php parser on the main site See readfile()
Have all your remote sites include the file as you've shown. Then use ftp functions in code to upload the included file whenever you change it. That's assuming remote computers. If it's all sites on one server then just symlink.
You could do: Create a file on remoteapiserver.com named code.txt and place within it: /* php code within no php tags. */ echo "hey"; PHP: And then on other websites call it like: <?php //execute the remotely located php code... eval(file_get_contents('http://remoteapiserver.com/code.txt')); ?> PHP: