About the install folder and changing its name

I'm still a starter with ZP, so I wanted to change the name of the install folder from /zenphoto to /albums. After that I found out that when I change the line RewriteBase /zenphoto into RewriteBase /albums in the .htaccess file everything works as before.

Two questions:
1. Can I do this without any problems or am I overlooking something?
2. During my upgrade to 1.1.6. I encountered the 'problem' that ZP says the RewriteBase folder is wrong and should be /zenphoto, so is this information included in the database somewhere? I checked my database but couldn't find anything like this.

Comments

  • 1. You have done the proper procedure for changing the folder name.
    2. Setup determines the folder that zenphoto is installed in and changes the .htaccess file accordingly (if file permissions allow.) So we can presume that zenphoto was still installed in the 'zenphoto' folder when you did the upgrade.
  • jackdaw Member
    About point 2.: No, my install folder was already renamed to /albums when I started with the upgrade (I renamed it yesterday ;)). Could it have something to do with the fact that I, at first, forgot to upload the new .htacccess file? Hmmm, but then ZP would have 'seen' that the name was set to /albums...

    Correction about the write permissions... The file was not writable by 'others', only by owner and group...
  • The new .htaccess file would have initially had the rewrite base as zenphoto/. Setup would have changed it from zenphoto/ to albums/ Setup gets the name it will set the rewrite base from the path it is run with. So if setup thought the name should be zenphoto/ then it must have been running from zenphoto/zp-core/setup.php.

    Perhaps it was changing the name from zenphoto/ or saying that zenphoto/ was not the correct base?
  • jackdaw Member
    Perhaps I have done more things 'wrong' than I thought...
    First, after uploading all the new files, I went to the base directory and viewed the album ( The guide says Setup.php will run, but it does not do this automatically!). Then I saw that the albums were not showing. Then I ran upgrade.php... and after that setup.php. :)

    Perhaps there can be made a few additions to the upgrade guide:

    # Backup your MySQL database.
    # Remove the “zen” or “zp-core” folder and the files in the home dir within your installation taking note of the database credentials in your zp-config file, you will need it in step 4
    # Download the latest version and upload it to your server and make sure the .htaccess file is writable
    # Once the files are uploaded, go to yoursite.org/gallery/zp-core/setup.php. Follow the instructions.
  • acrylian Administrator, Developer
    You only need to run setup.php, upgrade functionality is included in that, too.

    I think we have that already on the download page and the user guide page: http://www.zenphoto.org/2007/12/installation-and-upgrading/
  • jackdaw Member
    Well, that was my point. It is suggested on that page that 'Setup will run', but it does not do this aumatically and not from within zp's root folder. You have to point the browser exactly to zp-core/setup.php...

    And there is no mention of the importance of the .htaccess file on that page either. There is some information about the .htaccess file on the troubleshooting page, but imho I think it should be in the shortlist for upgrading.

    (The bold lines were my suggestions to add ;))
  • acrylian Administrator, Developer
    Actually setup.php indeed should run automatically... Sorry, missed the bold lines.... I will add that
  • Setup.php will run automatically IF the revision of the software you have uploaded is different from the revision last run. So, if Setup did not run it is an indication that the upload did not do what you expected.
Sign In or Register to comment.