SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Enthusiast
    Join Date
    Aug 2001
    Location
    san francisco, ca
    Posts
    74
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Permission Denied

    Hi,

    I get this error when my script tries to write to directory /newsdata

    Warning: fopen("/home/sites/site1/web/newsdata/ArticleCat.wmn","w") - Permission denied in /home/sites/site1/web/newsadmin/wmnews.php on line 356

    Warning: Supplied argument is not a valid File-Handle resource in /home/sites/site1/web/newsadmin/wmnews.php on line 357

    Warning: Supplied argument is not a valid File-Handle resource in /home/sites/site1/web/newsadmin/wmnews.php on line 358

    directory is chmod to 777 and mysql user has been granted all priviledges.

    Someone suggested that "the apache run in other user , and not in your user" and I have to chown user:group /path/dir/file.php

    But what does it have to do with mysql? Mysql is using another set of username and pass.

    Lines 357 and 358 as follows:

    $contents.="</td></tr></table></td></tr></table>";
    $fn=trim($article_catfile);


    Any ideas?

  2. #2
    SitePoint Guru prequel's Avatar
    Join Date
    Nov 1999
    Location
    Brisbane, Australia
    Posts
    682
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    did you chmod 777 ArticleCat.wmn ?

  3. #3
    SitePoint Enthusiast
    Join Date
    Aug 2001
    Location
    san francisco, ca
    Posts
    74
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    THanks! I thought I chmod the directory and the files in it, but it wasn't. I had to su to admin to do it. I'm new to linux. So, how do allow other users to change permission?

    Thanks,

    Nieto


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •