I am trying to write a string to a newly created file but when I write it to my newly create file I see the value of the string, but what I want actually is the string to show like $id = 15; but I only see 15 please someone should help me out I have been on this for hours
if (file_exists($file)) {
$newfile = "../".$low.$row["page_id"].".php";
$url = "../".$low.$row["page_id"];
$create = fopen($newfile,"w");
$addfile = "<?php include '../page.php'; ?>";
$write = fwrite($create, $addfile);
fwrite( $create, "<?php $id = $pid; ?>" );
}
what I want is to see $id = $pid
inside the newly created file but instead, I see the value it store