Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Need Some PHP Help!
#2
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;
?>

Reply


Messages In This Thread
Need Some PHP Help! - by microchip13 - 03-11-2006, 03:35 AM
Re: Need Some PHP Help! - by TheTominator - 03-11-2006, 04:40 AM
Re: Need Some PHP Help! - by microchip13 - 03-11-2006, 05:08 AM
Re: Need Some PHP Help! - by TheTominator - 03-11-2006, 05:23 AM
Re: Need Some PHP Help! - by TheTominator - 03-11-2006, 05:33 AM
Re: Need Some PHP Help! - by microchip13 - 03-11-2006, 05:37 AM
Re: Need Some PHP Help! - by shadow - 03-11-2006, 07:00 AM
Re: Need Some PHP Help! - by microchip13 - 03-11-2006, 02:18 PM
Re: Need Some PHP Help! - by TheTominator - 03-11-2006, 04:08 PM
Re: Need Some PHP Help! - by wowzer - 03-11-2006, 04:13 PM
Re: Need Some PHP Help! - by microchip13 - 03-11-2006, 10:08 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)