Quote:
Code:
fopen ("$file", "wb");
|
this is opening the file as
Write
Binary, I'm not sure that's what you want, when you wan't to use
readfile() on it.
If you plan on using readfile(), then you won't need the fopen(), allready your fopen() will lock the file for writing, befor you start reading from it and in php it is not allowed to have a file-pointer which is intended to write to a file, at the same time as you want to read from it.
Code:
<form name="form1" method="post" action="savefile.php">
<p><span class="consign style2">EDIT FILE:</span><span class="style1"><br>
</span><span class="headerlink">HERE IS YOUR FILE WHICH YOU SELECTED FROM YOUR FILEMANAGER </span></p>
<p><span class="style1">
<textarea name="editarea" cols="60" rows="50" id="editarea"><?php readfile($menu1);?></textarea>
should do it, unless you have a real intention on having to open a filepointer to the file.