index.php vs. index.html

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
lucky
New Member
New Member
Posts: 5
Joined: Mon Mar 09, 2009 1:43 pm

Re: index.php vs. index.html

Post by lucky »

it is easier to change it on the server side....try
DirectoryIndex index.php index.htm index.html
alby

Re: index.php vs. index.html

Post by alby »

SchPeter wrote: So to summarize what I want: if I get into the cmsms site I want the "Home" menu point to refer to http://mydomain.com/index.php
Why you don't rename index.html to something_else.html?

Alby
alby

Re: index.php vs. index.html

Post by alby »

SchPeter wrote: Because I want visitors to arrive into index.html and then they can choose static and cmsms part. In this case the home button direct me to the relative (index.html) path.
Excuse the question but: have you client that calling "directly" index.html? Very strange...

However you can do a http Redirect in .htaccess index.html -> something.html (if someone go directly in index.html)
and in your CMSMS "home" put a link to something.html for static page

Alby
dcleckley
Forum Members
Forum Members
Posts: 127
Joined: Fri Mar 06, 2009 2:13 pm

Re: index.php vs. index.html

Post by dcleckley »

SchPeter wrote: No, I haven't... but I have clients (all) that call http://mydomain.com/ and then they can choose between static part and cmsms part (different topic... situation came from the previous static site I had no time to convert cmsms) but when client get to cmsms part I want them to stay within it even they use home button. That is why I try to find how to set home button to http://mydomain.com/index.php
I hope I was clear.  ::)
Peter
OK.  This sounds simple.  I'm going to basically summarize your problem so that I understand it.  Correct me if I'm wrong.

You want the user to come to the index.html page first.   From the index.html page, the user will be able to choose a static site, or the CMSMS site.  If the user chooses the CMSMS site, you need to ensure that when they click 'home' that it contains them within the CMSMS site. 

Well, it should work for you that way anyway.  When you click on a menu item within a CMSMS site (for instance "Events"), you should get an address that looks like: "www.domain.com/[u]index.php?page="Events"[/u].  You see, the page is called via the index.php file.  So the user will be contained within the CMSMS site automatically, and will never be redirected back to the index.html page unless they physically type "www.domain.com" in the address bar.

I hope that I'm being helpful here.  If you are hosting from a linux box, this is how it should work for you by default.
Last edited by dcleckley on Tue Mar 31, 2009 9:24 pm, edited 1 time in total.
alby

Re: index.php vs. index.html

Post by alby »

SchPeter wrote: I hope I was clear.  ::)
Now yes  :)

SchPeter wrote: That is why I try to find how to set home button to http://mydomain.com/index.php
it's not possible, you must hack code for this

Alby
dcleckley
Forum Members
Forum Members
Posts: 127
Joined: Fri Mar 06, 2009 2:13 pm

Re: index.php vs. index.html

Post by dcleckley »

Did some research and found that the order is default.html, index.html and index.php.  Name the intro page default and redirect after intro is complete to index.php.  All should be good.  I've done it myself and it works great.  Hope this helps.
jmcgin51
Power Poster
Power Poster
Posts: 1899
Joined: Mon Jun 12, 2006 9:02 pm

Re: index.php vs. index.html

Post by jmcgin51 »

dcleckley wrote: Did some research and found that the order is default.html, index.html and index.php.
Keep in mind that this is server/host specific, so these settings may not apply to every situation.
dcleckley
Forum Members
Forum Members
Posts: 127
Joined: Fri Mar 06, 2009 2:13 pm

Re: index.php vs. index.html

Post by dcleckley »

jmcgin51 wrote:
dcleckley wrote: Did some research and found that the order is default.html, index.html and index.php.
Keep in mind that this is server/host specific, so these settings may not apply to every situation.
I agree and should have mentioned that.  Thanks!
User avatar
Ricko97
Forum Members
Forum Members
Posts: 65
Joined: Wed Jan 07, 2009 10:14 pm

Re: index.php vs. index.html

Post by Ricko97 »

SchPeter, I may be overlooking something here but why don't you just recreate index.html in CMSMS, uncheck "Show in Menu" and set it as the default page?

I have something similar one one of my sites where there is a splash page (www.mydomain.com), and the homepage is www.mydomain.com/home (or, without pretty URLs: www.mydomain.com/index.php?page=home).
Last edited by Ricko97 on Sun Apr 26, 2009 1:26 am, edited 1 time in total.
viebig

Re: index.php vs. index.html

Post by viebig »

That seens easy. like Ricko97 said:

1. Pick your custom home code and put it inside a template in CMSMS

2. Create a new Page and set the template within that you created previously, set to dont display on menu

3. On Content -> Pages, set this page as Default

I think that would work.
Jeff
Power Poster
Power Poster
Posts: 961
Joined: Mon Jan 21, 2008 5:51 pm

Re: index.php vs. index.html

Post by Jeff »

You actually don't need to create the static index.html in cms, because directory indexing will go to the index.html first.

You just need to set blank page (not shown in the menu so no one will go to it) as default.

Then the breadcrumbs/menumanager will use full address for the "home" page.

Jeff
User avatar
lemonaid
Forum Members
Forum Members
Posts: 77
Joined: Mon Sep 22, 2008 7:44 am

Re: index.php vs. index.html

Post by lemonaid »

Thanks adjprog  that was the logical solution I was seeking. 

I had a 'splash' page  at

www.mysite.com/index.html  linking through to

www.mysite.com/index.php

Using the home (default) page link in the menu of CMSms sent the user back to the splash page (www.mysite.com)  which was not desireable.

Using adjprog's solution and changing the link from the splash to www.mysite.com/index.php?home (or whatever) I was able to overcome the problem.
Pierre M.

Re: index.php vs. index.html

Post by Pierre M. »

Hello,

May be http://forum.cmsmadesimple.org/index.ph ... #msg166104 can be interesting for you.

Pierre M.
LouiseW
Forum Members
Forum Members
Posts: 83
Joined: Tue Jun 10, 2008 6:59 pm

Re: index.php vs. index.html

Post by LouiseW »

ajprog wrote: You actually don't need to create the static index.html in cms, because directory indexing will go to the index.html first.

You just need to set blank page (not shown in the menu so no one will go to it) as default.

Then the breadcrumbs/menumanager will use full address for the "home" page.

Jeff
This works fine!
The standard page in CMSMS is now page 'redirect', not shown in the menu.

On my server index.php was the first page that showed. I made a .htaccess file with these lines:

Code: Select all

<IfModule mod_dir.c>
    DirectoryIndex index.html index.htm index.php
</IfModule>
This made my static index.html page show first.
This page contains a link to http://www.mywebsite.com/index.php?page=home
The Home button in the CMSMS menu also refers to this page.

Thanks ajprog!
Thanks for your help
I use CMS Made Simple 1.6 "New Caledonia"
Post Reply

Return to “Modules/Add-Ons”