The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

auto generate .htaccess file

Discussion in 'General Discussion' started by JoelP, Nov 26, 2006.

  1. JoelP

    JoelP Member

    Joined:
    Oct 2, 2005
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    1
    Hi,

    I have a few php pages that are pretty resource hungry so I've made a script to cache them as static html files. I was then going to have the script modify the .htaccess file to redirect to the html files according to which had an up-to-cache.

    Unfortunately, after writing the whole caching script I realised I could not edit the .htaccess file because PHP was running as nobody. I tried changing the permission on .htaccess as a temporary solution, but they kept changing back. I suppose I'll have to look into using phpsuexec. But my question is:

    What causes the .htaccess permissions to change back? Can I prevent this behaviour?

    Also, if anyone has any suggestions as to how I might get the caching script working without using phpsuexec, I'd be glad to hear.

    Thanks.
     
Loading...

Share This Page