i'm using this code to write text into n.aliases.php at the correct spot (*ENTER TXT HERE*):
PHP Code:
$fn = "n.aliases.php";
$cont = file_get_contents($fn);
$clrf = fopen($fn,'w');
$etp = "*ENTER TXT HERE*";
$trw = "\$lion = \"lioness\";";
$cont = str_replace("$etp", "\n$trw\n$etp", $cont);
fputs($clrf, $cont);
and it all works fine.. except this line:
PHP Code:
$cont = str_replace("$etp", "\n$trw\n$etp", $cont);
- i want it to break the line at the "\n" marks.. but it doesn't do that, and instead, i just get a huge block of text
am i doing something wrong?
Last edited by biocrite; 07-26-2004 at 05:11 PM..
|