Menu

Failed opening required theme.php. 1st try.

Help
2004-02-20
2004-02-23
  • Thomas Gail Haws

    I am on a Linux server.  I used terminal to unzip and untar phpGedView 2.65.3 and researchLog to http://www.hawsedc.com/phpGedView/, I did chmod 777 on config.php, authenticate.php, and the "index" directory, and then tried to load in my browser.

    Warning: main(themes/standard/theme.php): failed to open stream: Permission denied in /home/happyhav/public_html/hawsedc/phpGedView/config_gedcom.php on line 129

    Fatal error: main(): Failed opening required 'themes/standard/theme.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/happyhav/public_html/hawsedc/phpGedView/config_gedcom.php on line 129

    Two questions:

    1) How do I fix this?

    2) Where can I find a rundown on the all the Unix-style permissions recommended for optimal phpGedView?  The Readme doesn't have it.  I'd like to see a file-by-file or folder-by-folder 777/755 etc. recommendation.  I'll be glad to donate time writing documentation once I get this figured out.

     
    • Anonymous

      Anonymous - 2004-02-20

      I had the same message initially. I found my original download did not have the folder structure intact. There was no Themes folder. I download again and there were several folders. That message went away.

      Regards,
      John

       
      • Thomas Gail Haws

        I unzipped (or untarred) the file from the Linux command prompt using a terminal, so the full directory structure is there.  Here's a paste directly from a browser file manager at my host:
            / public_html / hawsedc / phpGedView / themes / standard / (Current Folder)

        By the way, this error is of course occurring in the following file:
        http://hawsedc.happyhavengraphics.com/phpGedView/editconfig.php

         
    • Daniel Kionka

      Daniel Kionka - 2004-02-20

      I can't help you with your error, but if you are going to write up Linux info...

      Instead of using chmod, I use chown -R apache.  I think the user running httpd depends on the Unix version, but it is apache (user id 48) on Fedora Core 1.

      We could include a sh script that fixes up things.  It could run "ps -ef | grep httpd" to find the right user and then run chown -R.

      Oh, I just realized this doesn't apply in your case.  You are installing in your own ~/public_html, so you do NOT want to chown apache, and probably can't.  When it is in a user directory, you need to use chmod.

      Boy, this is complex.  Someone should document it!

       
    • Thomas Gail Haws

      Here's the solution:

      My permissions were (as I suspected) wrong.  Apparently my server has default permissions other than 755.

      What I did:
      Using PUTTY.EXE in SSH mode, I opened a terminal at my server, logged in using my regular name and password.

      Then I used the Unix/Linux commands ls and cd to list (see where I am) and change directories to just above the phpGedView directory.

      Then I typed
      chmod -R 755 phpGedView/*.*
      That changed everything to 755 (read and execute permissions)

      Then I typed
      cd phpGedView
      chmod 777 config.php
      chmod 777 authenticate.php
      chmod -R 777 index/*.*

      That did the trick.  I think the docs need to say "everything else (files and directories) needs read and execute (755) permissions"

      Any way I can help document this?

       
    • Mark Hattam

      Mark Hattam - 2004-02-23

      If your Linux server is out of your direct control (eg it's at a web-hosting service), then surely it'd be better to ask the server admin to set the default to 755 ... isn't it a bit pointless otherwise if the intention is to serve a website?

      The only other values that'd be useful would be 775 and 777.

      Or am I missing the point?

      Mark

       
      • Thomas Gail Haws

        True.  In my case the server is under my control.  At least my account is.  I don't know how the crazy permissions got set, but they were 744 or something like that.  I now know that all files and directories need to be 755 except for the files mentioned in the docs.  I think it would be wise to put that explicitly in the docs.

        To wit,
        Make sure all files and directories have permissions set to 755, or read and execute for everybody and write for owner.  Then change permissions to 777, read-write-execute for everybody on the following files:  blah blah blah.

        That would have made my installation perfect.

         

Log in to post a comment.