Is it possible to code the template to show a home page “post” or page? I’d like to make the index template a “page” template with the home page default (if you go to site or index.php) and individual page if not.
Is this possible? I’ve looked through the documentation but either overlooked it or it’s not there… or I’m just searching for the wrong terms.
I do this by creating a weblog called ‘home’, and then checking on my index page for the existence of a {segment_1} - if there’s not one, that must be the home page so I render that weblog.
My question is similar. I want specific home page content, but I have no reason to want to publish multiple entries in the ‘Home’ blog. It only needs one block of information, but I want it to be easily editable in the future. Once I hand off the site to the client, it might be confusing to have the ability to create multiple entries in the ‘Home’ weblog, but only one ever showing up on the home page.
This was by far my biggest gripe with EE when I started out. I wanted exactly the same as that Shinka - there are ways to pull it off (this is a good read) but now I’m pretty comfortable with the ‘multiple posts per section’ thing and so far (though we’ve only signed off one EE project as I write this) so are the clients.
Slightly off topic, the guys from 37signals who write Basecamp etc wrote a really good piece on their site about how people find other ways to do stuff. For example, they don’t have a priority setting in Basecamp, and they noticed people were doing things like adding a * before the task title if it was important. I think the same is kinda true of this, you just have to work differently and it turns out you maybe didn’t REALLY need it afterall.
Well, I do really need it, as plenty of websites need a static home page. Either some sort of ‘welcome’ text or a description of the product, etc. Yeah, I could just hard code the text into the *index template, but then my clients wouldn’t be able to edit it once it’s there. I tried installing the ‘Static Pages’ module but then realized it had been replaced by the standard ‘Pages’ module. Maybe we’ll see a feature like this implemented in EE2?
Thanks for the suggestions. We ended up going with a much more simplified approach. We just added a “Home Page” to the default weblog (the same that will house the pages) and created two templates, one for index and one for “pages”.
The index template just specifies the entry: entry_id="1"
There’s any number of ways to do it. Yes, the Pages module should be doing that, or variables (perhaps a Fresh, or a regular Global Variable?). Or you use a “static” weblog, even if it only contains one entry, no harm in that.
@shinka Yes, almost every website I’ve worked on requires some ‘static’ content but the fact that you can republish it has worked for me as more of a pro than a con. It also adds a neat element of version control - client can either edit the existing entry or post a new one.
Ingmar…what’s a ‘static’ weblog? Perhaps something I missed when going through the documentation?
Andy, yes I agree, and I think, as a whole, ExpressionEngine just blows everything else out of the water, I just know that some clients are dumb as boards and making it easy as possible for them is a good thing.
Thanks for your quick responses, as well. I’m beginning to believe the hype that this is one of the best support forums on the web.