I'm tryning to create a new php file from php.
My final php file must look like this:
<?
$text_1 = "Text";
$text_2 = "Banana";
?>
Actually my php to generate it is the following: $file = fopen("../lang/_____fr-CA.php", "w") or die("Unable to open file!");
<?
$datas .= '$text_1 = "Text"; n ';
$datas .= '$text_2 = "Banana"; n ';
$datas = nl2br("<? n".$datas."n ?>");
fwrite($file, $datas);
fclose($file);
?>
My problem is the generated php looks like this:
<? <br />
$text_1 = "Text"; n$text_2 = "Banana"; n<br />
?>
