Jump to content

Help?


Lol5916

Recommended Posts

$p = $_POST['log']
$l = file_get_contents(file.php)
$log = str_replace("replace", "", $l)

 

How do I make it so that the word "replace" in "file.php" get's replaced by the output of $p?(form "log")

 

Try:

 

$p = $_POST['log']
$l = file_get_contents(file.php)
$log = str_replace("replace", $p, $l)

Link to comment
https://forums.phpfreaks.com/topic/121104-help/#findComment-624329
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.