> Hi > > I am new to PHP and I'm trying that my script checks if a directory exists > and > if not, it should create it. I'm doing it with mkdir() but it returns this > error message: > > Warning: mkdir(0): Permission denied in /xxxxxx on line 32 > > I wonder what kind of permissions should I set. This should be doable by > any > visitor. > > Thanks for your help. > > Percy
It you're trying to do this through a web server, then permissions need to be set with the web server. Directories and files need to be owned by the whatever UID the web server runs as (nobody, www, etc). If you're running it through a stand alone script, well then, if you don't own the directory or you're not root, that's probably the problem. -- --Matthew Sims --<http://killermookie.org> -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php