Page 1 of 1

Execute/run remote php page?

Posted: Wed Dec 21, 2005 4:11 pm
by lemonfreshmedia
Hi I have a php page which needs to be executed every time a page on another server is loaded.
I 'm having trouble getting my host to allow xslt on one server.


Does anyone know how I can do this?

Posted: Wed Dec 21, 2005 4:51 pm
by LiveFree
You can try that with include statements, just include the file at the top of the file it shall be executed from

Posted: Wed Dec 21, 2005 7:04 pm
by josh

Code: Select all

<?
$url = 'http://example.com/myscript.php';

$result = file_get_contents($url);
if ($result) {
echo 'script said: '.htmlentities($result);
} else {
echo 'error!';
}
?>
try this