I want to be able to send a few variables to a file through file_get_contents().
This is firstfile.php:
<?php
$myvar = 'This is a variable';
// need to send $myvar into secondfile.php
$mystr = file_get_contents('secondfile.php');
?>
This is secondfile.php:
The value of myvar is: <?php echo $myvar; ?>
I want the variable $mystr to equal 'The value of myvar is: This is a variable'
Is there any other function that will let you do this in PHP?
 
     
     
     
     
     
     
    