03-11-2006, 04:40 AM
microchip13 Wrote:
-------------------------------------------------------
> First off, how can I store some PHP variables into
> a file? Maybe like:
>
> $variable =
> ("/var/www/html/whatever/whatever.txt");
How about making the file itself be PHP code that assigns the variables.
Then execute a
require "variables.php";
line in your PHP code to read in the file and execute it there to assign the variables.
The file variables.php would then be something like:
$variable = "my dog has fleas";
$another = 12;
?>
-------------------------------------------------------
> First off, how can I store some PHP variables into
> a file? Maybe like:
>
> $variable =
> ("/var/www/html/whatever/whatever.txt");
How about making the file itself be PHP code that assigns the variables.
Then execute a
require "variables.php";
line in your PHP code to read in the file and execute it there to assign the variables.
The file variables.php would then be something like:
$variable = "my dog has fleas";
$another = 12;
?>