Re: Create .php file with php

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 6/25/07, Marius Toma <marius@xxxxxxxxxxxxxxxxxxxx> wrote:
I can not create .php files from PHP. I can save them as *.php5, *.php3,
asp, *.txt , etc... but not as .php. I tried both touch and fopen but
none of them worked.

I'm running PHP 5.1.6 on Apache 2, safe_mode is off

Is this a security measure somewhere? How can I bypass it?

Thank you,
Marius

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



   I doubt it will help you, but with a default installation of 5.2.2
on a Linux box (fresh install), I was able to do this from the CLI
with no issues whatsoever:
<?
       $handle = fopen('writetest.php','w');
       fwrite($handle,"This is a test.");
?>

   I know that you said that you were able to write a file, but are
you using the correct parameters in your .php writes to create or
append to a file (as needed), and are the write permissions set
properly for the exact directory to which you're attempting to write?


--
Daniel P. Brown
[office] (570-) 587-7080 Ext. 272
[mobile] (570-) 766-8107

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux