- This topic is empty.
December 14, 2011 at 6:03 am #35637
Sorry if this is a silly question but what is the difference between these templates in WP, and should they just be the same?December 14, 2011 at 6:06 am #92687chrisburtonParticipant
Index is where your blog posts will show (site.com/blog) and home would be your homepage (site.com).
However, you can make the index page your homepage.December 14, 2011 at 6:10 am #92688
So you don’t necessarily need to have an Index if you don’t have a blog per se? You can simply have the Home.December 14, 2011 at 6:14 am #92689chrisburtonParticipant
I’m not sure I would delete it, maybe you’ll change your mind. I think blogging is important, not just for others, but for you as well. It shows your progress.December 14, 2011 at 6:15 am #92690BrightonmikeMember
No. You have to have an index. You’d do well to read up on wordpress template hierarchy.December 14, 2011 at 6:20 am #92702
@Brightonmike – thanks, I have just been reading that, hence my confusion. If you not using a blog but just using posts, what should it be used for if I have to have it?December 14, 2011 at 7:03 am #92696
Sorry to labor on this folks. So I can set the Index to be the Home page if I want to, provided the Index template is there at all costs? A Home template is therefore not required. All I need to do is assign the Index to the home page in the back-end if I want that as the basic set-up. Is that right?December 14, 2011 at 7:23 am #92701
@Senff – I sort of get it. But if you want Index to be the home page, that is fine? I notice you can’t assign the Index template to a page.December 14, 2011 at 7:47 am #92709
@Senff – Ok, I have assigned the front page to be the Home in the settings and it works fine. I am still a little unclear what the Index file should be used for if you are not using a blog?December 14, 2011 at 8:49 am #92718
@Senff – I totally get it now. That is a really clear explanation and I’m petty sure I have got my head around it. I really appreciate you going to lengths that you did in your last post because it wasn’t quite clicking before :)December 14, 2011 at 6:15 pm #92762TheDocMember
index.php is the fall back for ALL pages.
For your home page, it’s recommended using either front-page.php or home.php. Never use index.php for your home page, it should be used as a ‘generic’ fall back.
I always use front-page.php and set that page in Settings > Reading.December 14, 2011 at 7:46 pm #92767TheDocMember
I’m referring to the index.php in your theme’s folder. See here: http://codex.wordpress.org/images/1/18/Template_Hierarchy.png
You can use it as the home page as long as you keep the code basic. The second you start adding things to the template that are specific to the home page only, you should be using home.php or front-page.php.
- The forum ‘Other’ is closed to new topics and replies.