I was looking for the same thing as you are for ages until i figured this out.
If anyone can see any problems with this then get in touch.
This is possible. You have to include the PHP page the same way as you would include a JavaScript File.
e.g.
In your HTML page put:
<SCRIPT LANGUAGE="JavaScript" SRC="http://youphpserver/yourphpfile.php"></SCRIPT>
The browser now thinks its including a JavaScript File.
Now output all of the PHP results in <yourphpfile.php> as:
document.write("variables can go in here");
below is an example of what yourphpfile.php would look like:
$array = array("first", "second" , "third", "fourth", "fifth", "sixth");
for ($i=0; $i < count($array); $i++)
{
?>
document.write("<br><FONT FACE='ARIAL' SIZE='2'><?=$array[$i]?></FONT>");
<?
}
any feedback would be good.
Cheers