OK... It's bee ahwile, but I have a problem with an undefined variable. Whenever I declare a variable on a page to be included on another, the variable comes up as an undefined variable. For example, if I was working on index.php, here is the code I would use:
On test.php, I would do the following:
When I run index.php, the error would read:
Any ideas? This used to be fairly simple, but with globals now set to off, it seems like a pain (although more secure). Is there a good way to handle this properly?
Code:
<?
include("test.php");
echo $abcd;
?>
Code:
<?
$abcd = "test";
?>
Code:
Notice: Undefined variable: abcd in index.php on line 1
Any ideas? This used to be fairly simple, but with globals now set to off, it seems like a pain (although more secure). Is there a good way to handle this properly?