Reply to PHP issues with file ownership

Your name:

Reply:


Posted by joniboy123 on 05/15/07 21:54

Hi,

I have a PHP script which creates new text files in the same directory
as itself. The new files are also PHP scripts and are built with a
line of code within them, which runs a function when they are browsed
to by the user.

E.g. the new file's contents are similar to <?php runFunction(83); ?>

However, because the new file was created by a script, it does not
have the same owner as the and the function fails. An exact copy of
the file uploaded from my FTP software works fine as it has the same
owner as my script.

The error I receive is that there is a safe mode restriction and the
uid/gid does not match.

I use a shared server, so am reluctant to edit the php.ini file.

I have tried to 'chown' the file after creation but it fails,
(probably because my script is not superuser).



I am running out of ideas, is there another way to change the
ownership to match? Or are there any other options that I can
investigate?


Thanks in advance,
Jon

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация