ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

How to make ExpressionEngine page my site's default home page?

August 26, 2009 4:42pm

Subscribe [2]
  • #1 / Aug 26, 2009 4:42pm

    tschmid

    4 posts

    I can’t figure out how to set an ExpressionEngine template as my site’s default index.php page that people arrive at when typing in my basic URL.

    I have a site I’ll call mysite.com. The current non-EE-powered home page for this is http://mysite.com/index.php. So if anyone types “mysite.com” in their browser, they technically arrive at http://mysite.com/index.php.

    However, I’ve set up an EE-powered version of my site. The template group is called “ee”, and the index for this group is index.php. So currently, my EE-powered blog resides at http://mysite.com/index.php/ee.

    How do I make my EE-powered page (mysite.com/index.php/ee) show up automatically when someone types “mysite.com” into their browser?

    Basically, I need a way to remove the template group (“ee”) from the URL, so it automatically goes to the EE-powered index.php rather than my current, old default.

    Does this make sense? I hope you can help! I’m by no means a PHP programmer but have a decent handle on HTML. I built the EE site after the main site, and thought it would be as simple as transferring the EE files to the root directory of my site and making sure all the settings are correct, but the Template Group name is getting in the way. Do I need to modify .htaccess or something so the browser goes to a page other than my original site’s index.php?

    Thanks!
    Tristan

    Update: I just tried setting my site’s default page, via my host’s IIS, to mysite.com/index.php/ee, but that didn’t work. It still goes to mysite.com/index.php

  • #2 / Aug 26, 2009 4:53pm

    Ingmar

    29245 posts

    How do I make my EE-powered page (mysite.com/ee/index.php) show up automatically when someone types “mysite.com” into their browser?

    The easiest way would be to remove the “old” index.php and move EE up a directory.

    Basically, I need a way to remove the template group (“ee”) from the URL, so it automatically goes to the EE-powered index.php rather than my current, old default.

    Be careful with your terminology here, this is probably not a template group but a simple subdirectory.

  • #3 / Aug 26, 2009 4:55pm

    Ingmar

    29245 posts

    Actually, I am a little confused about your setup. Do you’ve got a link to it? Normally, calling http://example.com/indx.php should load the default template of your default template group, provided EE is installed in that directory.

    Also, what version and build are you using?

  • #4 / Aug 26, 2009 5:19pm

    tschmid

    4 posts

    Using ExpressionEngine v 1.6.7 build 20090515.

    My site’s current default home page is: http://indyhumane.org/. So when people type indyhumane.org in the browser, they auto-arrive at http://indyhumane.org/index.php.

    However, I’m trying to make it so my EE-powered page (currently at http://indyhumane.org/index2.php/hsi) becomes the home page people auto-arrive at when they type indyhumane.org into the browser.

    As you mention, I tried removing the old index.php, and EE’s files are already in the site’s main directory. When I removed the old index.php, renamed and referred all the EE info to index.php, I just got blank screen UNLESS I typed indyhumane.org/index.php/hsi into the browser.

    So the problem is that the EE-powered page keeps referring to that appended “hsi” at the end of the URL. “hsi” is the Template Group (see attached file - this shows that “hsi” is the Template Group, which must be included at the end of the previous link above in order for the page to be viewable.)

    I hope I’m explaining this clearly enough 😊 Thanks for your help!

  • #5 / Aug 26, 2009 5:29pm

    Ingmar

    29245 posts

    The first thing to ask, why does http://indyhumane.org/index2.php not work? Is it not the default template group? Please go into your Template, open hsi > Edit Group > Make the index template in this group your site’s home page?

    Once you’ve done that bringing up EE should automatically load that template group. After that you should be able to remove / rename the old index.php.

  • #6 / Aug 26, 2009 7:19pm

    tschmid

    4 posts

    Ingmar, thanks - I changed this, and the link you last provided works now.

    However, none of the PHP includes are working - are includes not allowed in EE?

    You’ll notice a banner at the very top of http://indyhumane.org is missing from http://indyhumane.org/index2.php and - much more importantly - the site’s navigation on the upper left of our original page is missing in the latter.

    I did some quick digging and it sounds like PHP includes are frowned upon, but the threads I could find about workarounds to PHP includes in EE only lead me to coding I didn’t understand at all :( (I assume maybe I should post a new thread for this issue.)

    Thanks!

  • #7 / Aug 26, 2009 7:28pm

    Greg Aker

    6022 posts

    PHP includes can be tricky within templates, it’s best to use the full server path when you are including the file.  May I ask what you are including that simply using an embedded template won’t do?

    =greg

  • #8 / Aug 31, 2009 5:54pm

    tschmid

    4 posts

    PHP includes can be tricky within templates, it’s best to use the full server path when you are including the file.  May I ask what you are including that simply using an embedded template won’t do?

    =greg

    Greg, I’m trying to include the banner at the top of http://indyhumane.org. I’d have to do some research on how to use an EE embedded template; any guidance is appreciated! 😊

  • #9 / Aug 31, 2009 5:57pm

    Ingmar

    29245 posts

    Take a look at the docs: sub templates are explained in some detail here.

  • #10 / Sep 03, 2009 12:08pm

    tschmid

    4 posts

    Greg & Ingmar,

    Thank you so much for your help! I used embedded templates & they worked wonders.

  • #11 / Sep 03, 2009 3:39pm

    Ingmar

    29245 posts

    I am very glad to hear that 😊 If you need further help, simply start a new thread, please.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases