coppermine-gallery.com/forum

Support => cpg1.4.x Support => Older/other versions => cpg1.4 miscellaneous => Topic started by: copperminepro on December 21, 2007, 09:03:14 PM

Title: Replacing index.php with static html, moving coppermine's index to gallery.php
Post by: copperminepro on December 21, 2007, 09:03:14 PM
Okay, Currently I have the default coppermine structure (I'm using sef_urls):

http://www.mysite.com/index.php - Homepage, category/album lists
http://www.mysite.com/index-1.php - First Category
http://www.mysite.com/index-2.php - Second Category
http://www.emobucket.com/thumbnails-12.html - Random Album
http://www.emobucket.com/thumbnails-20.html - Another random album

What I want to do is replace index.php with index.html, and move index.php to gallery.php, effectively making my structure this:

http://www.mysite.com/index.php - Homepage
http://www.mysite.com/gallery.php -  Category/Album lists
http://www.mysite.com/index-1.php - First Category
http://www.mysite.com/index-2.php - Second Category
http://www.emobucket.com/thumbnails-12.html - Random Album
http://www.emobucket.com/thumbnails-20.html - Another random album


See, I want to keep index-1.php and index-2.php where they currently are.

What I'm thinking is that I need to do this:

Rename index.php to gallery.php
Upload my new index.html
Re-write gallery-1.php to index-1.php using htaccess

But my question is, where in the script would I tell coppermine the location of the index.php file?

Is this even possible? As of now when you come to my site you are greeted with a modified coppermine index.php that is VERY, VERY resource demanding. It's loading my server and with my increasing traffic it seems I'm upgrading my server every 2 weeks, hopefully this could reduce the load.

Title: Re: Replacing index.php with static html, moving coppermine's index to gallery.php
Post by: Nibbler on December 21, 2007, 09:13:33 PM
Keep it as index.php and add in an index.html. Make the index.html the default using DirectoryIndex in .htaccess if it isn't already default.
Title: Re: Replacing index.php with static html, moving coppermine's index to gallery.p
Post by: copperminepro on December 21, 2007, 09:22:25 PM
Ahh...

So make the server look for index.htm / index.html first, than duplicate index.php as gallery.php, but keep the old index.php so the categories still work fine?

Is there anything I could do to make index.php not accessible

so say someone types in mysite.com/index.php, I don't want them to be able to access it  ???
Title: Re: Replacing index.php with static html, moving coppermine's index to gallery.php
Post by: Nibbler on December 21, 2007, 09:34:04 PM
Use a redirect or rewrite.