Hi
This seems like a simple question, but I'm not sure where to find the answer.
While I'm working on my CMSMS site, I've got a holding page (index.html). Trouble is, when I'm using the CMSMS site, the home page links to this holding page, NOT the index.php page. ie 'Home' links to the root (www.domain.com/) not the index.php page.
How can I change this? I want to be able to show the site to other people before I make it live, and I'd like it to work smoothly.
Many thanks
Jo
[SOLVED] change homepage URL
[SOLVED] change homepage URL
Last edited by jocando on Mon Jun 29, 2009 12:59 pm, edited 1 time in total.
Re: change homepage URL
On your page screen change your default page to a page that you don't use.
The CMSMS system automatically puts the default page as 'yourdomain.com/' if you don't want that then add a blank page that you don't use (doesn't show in the menus) and set it to be the default.
The CMSMS system automatically puts the default page as 'yourdomain.com/' if you don't want that then add a blank page that you don't use (doesn't show in the menus) and set it to be the default.
Re: change homepage URL
Thanks for replying, but I'm not sure exactly where to do this. What 'page screen'?
Jo
Jo
Re: change homepage URL
your problem is that your server calls index-files in a defined sequence when no page is called...
so your homelink which points to the root of your CMSMS directory opens that index.htm there
you can change the sequence of index-file-types in the .htaccess file:
if given in that way, first index.php will be loaded if exists, second index.htm if index.php does not exist..
sorry... this posting is not the right answer to your problem..
so your homelink which points to the root of your CMSMS directory opens that index.htm there
you can change the sequence of index-file-types in the .htaccess file:
Code: Select all
DirectoryIndex index.php index.htm index.html
sorry... this posting is not the right answer to your problem..
Last edited by Connie on Mon Jun 29, 2009 12:59 pm, edited 1 time in total.
Re: change homepage URL
Many thanks. I'll try that.
I also now understand the workaround from ajprog and have got that working as well.
Thanks to all!
Jo
I also now understand the workaround from ajprog and have got that working as well.
Thanks to all!
Jo
Re: [SOLVED] change homepage URL
Hello,
May I add my recipe ?
1-I create a page to be the homepage (set it as the default like ajprog) and call it (alias) 'index'.
2-I use a '.html' extension, with hierarchy like /some/path/to/a/page.html hence the homepage is /index.html (academic, isn't it?)
3-I use the opposite of Connie's DirIdx : DirectoryIndex index.html index.php
4-I use a .htaccess at the root to 302 redirect / to /index.html
This way :
1-When I temporary put a index.html static file at the root it is served as the homepage (maintenance or hacking convinience).
2-When I use CMSms alone (no static html file) the homepage is still /index.html (url stability)
3-Audience to homepage is measured as hits to /index.html (domain.tld/ alone doesn't matter) in all cases.
Pierre M.
May I add my recipe ?
1-I create a page to be the homepage (set it as the default like ajprog) and call it (alias) 'index'.
2-I use a '.html' extension, with hierarchy like /some/path/to/a/page.html hence the homepage is /index.html (academic, isn't it?)
3-I use the opposite of Connie's DirIdx : DirectoryIndex index.html index.php
4-I use a .htaccess at the root to 302 redirect / to /index.html
This way :
1-When I temporary put a index.html static file at the root it is served as the homepage (maintenance or hacking convinience).
2-When I use CMSms alone (no static html file) the homepage is still /index.html (url stability)
3-Audience to homepage is measured as hits to /index.html (domain.tld/ alone doesn't matter) in all cases.
Pierre M.
Re: [SOLVED] change homepage URL
Pierre,Pierre M. wrote: 4-I use a .htaccess at the root to 302 redirect / to /index.html
For those of us (like me) that only copy and paste to the .htaccess file. Can you paste the code for your 302 redirect?
Re: [SOLVED] change homepage URL
Hello again,
try something like :
But test and tune. This is very basic. Simple "copy and paste" is unwarrantied.
Have fun with CMSms
Pierre M.
try something like :
Code: Select all
RewriteEngine on
RewriteBase /
RewriteRule ^$ index.html [R=302,L]
Have fun with CMSms
Pierre M.