If I remember correctly, variables need not be passed to an included file. I wrote some test code some time ago to make sure, let me find it.
shuffles through some code
Darn, couldn't find it.
Okay, try this:
Save these two programs-
program1.php
<?php
$var1=5;
echo "Variable 1 is $var1<BR>";
include("http://www.myserver.com/mydir/program2.php")
echo "Variable 1 is now $var1<BR>";
echo "Variable 2 is $var2<BR>";
?>
program2.php
<?php
$var1= $var1+8;
$var2="now containing text";
?>
This should (hopefully) output:
Variable 1 is 5<BR>
Variable 1 is now 13<BR>
Variable 2 is now containing text<BR>