WordPress.org

Ready to get started?Download WordPress

Forums

Static Front Page + Blog (24 posts)

  1. likorish
    Member
    Posted 7 years ago #

    I'm trying to set up WordPress with a static front page, plus a separate page that shows blog-style entries. I'm using the Copyblogger theme (if that helps), but for whatever reason - maybe the lateness of the hour - I can't figure out how to create a separate blog page and have it show up in my site's navigation. Any tips are appreciated.

  2. Root
    Member
    Posted 7 years ago #

    Hack about in your admin area. You can set a static front page there.

  3. JamesICT
    Member
    Posted 7 years ago #

    If you create a page using the 'Write Page' option and then save it, you can then set this as the front page.

    You do this by going to Options - Reading - and selecting the Static page option. Choose the page you just created from the drop down box and this will now show as the front page.

    Your posts and any other pages will be accessed via sidebar menus, top navigation links or whatever else you set up.

  4. likorish
    Member
    Posted 7 years ago #

    Hi JamesICT/Root,

    Yes, I've created the static front page already, but the only other pages that are available in navigation are the 'about' page and the 'archives' page - the entries page is nowhere to be found. Do I have to create a special page just for the entries?

  5. Root
    Member
    Posted 7 years ago #

    The entries page as you call it will be the index.php. It should be there working as usual. Unless you did something odd with it.

  6. likorish
    Member
    Posted 7 years ago #

    I didn't do anything odd to it - I made the static page the front page of my site by going to Options > Reading, and then I suddenly didn't have a blog page anymore. Now when I load the index.php page, I see the static page I created.

    If I go back into Options > Reading and change the front page options so that the front page displays a list of posts, then I see my list of posts. I could be wrong, but it seems that when I make the static page the front page, it's overwriting the index.php page. I don't know if that makes any sense. I appreciate your help this far.

  7. Root
    Member
    Posted 7 years ago #

    You need to forget what goes on in static sites. WP only has one *page* that is index.php. It is dynamic. It can load a page of static content. Or your posts. But as a fix you could save index.php as home.php. Its magic.

  8. stml
    Member
    Posted 6 years ago #

    likorish - I know what you mean, and I don't have an answer for you.

    What Likorish means is, when the front page is static, what should you use as your main posts page - the page that would usually appear as the home page?

    My workaround for this has been to create a separate template with a query_posts loop in it, and point another static page at this, but it isn't a good solution.

  9. Colin Helvensteijn
    Member
    Posted 6 years ago #

    <?php
    /*
    Template Name: Blog
    */

    // Which page of the blog are we on?
    $paged = get_query_var('paged');
    query_posts('cat=-0&paged='.$paged);

    // make posts print only the first part with a link to rest of the post.
    global $more;
    $more = 0;

    //load index to show blog
    load_template(TEMPLATEPATH . '/index.php');

    ?>

    Save that as blog.php in your themes directory and select Blog as page template for your blog page.

  10. bloggurl
    Member
    Posted 6 years ago #

    Raptor NL,

    Will this work in version 2.3? and does this assume the installation is in the root? I'm about to try it!

  11. mstenzel
    Member
    Posted 6 years ago #

    Root,
    What, exactly, does changing index.php to home.php do?

    In case anyone's getting stuck with the "2 Home page" problem, I got lucky on some code-stripping ("lucky" because I really don't know what I'm doing) and was able to remove the WP-default "Home" and replace it with my own static page.

    See here.

  12. Cornell_Finch
    Member
    Posted 6 years ago #

    Yes, I know it's bad form to bump such an old post, I just wanted to say that the method that raptorNL posted above for showing the blog posts works a treat with a static front page and WP 2.3.1.

    Collin

  13. ynotweb
    Member
    Posted 6 years ago #

    Sorry, came across this looking for something else and seems like the answers overcomplicate the process (for version 2.1 and up).
    To have a static front page and retain your seperate recent posts/blog page, you:
    A) Create your home page under Write>Pages
    B) Create a seperate (blank) Page(again, Write>Pages) called "Blog" or "Recent Posts" or whatever you want the link text to be in your navigation. You can type nothing or anything you want in the body (I usually type "this is a placeholder".) as this text is never displayed -- it is replaced with the blog entries instead.
    C) Go to Options > Reading.
    D) Select "Front Page Displays a Static Page"
    E) Define Front Page as whatever page title you gave your home page in step A.
    F) Define Posts Page as whatever page title you gave your blog "page" in step B. No need to create a special template- whenever someone navigates to this "page" they get the X most recent posts as defined on the bottom half of Options>Reading.

  14. matthew123
    Member
    Posted 6 years ago #

    ynotweb - i hv done your steps.That's a good idea but how can I remove the Comments, Tags, Categories for that particular static page? bcos comments are more like to be in post section only.huhu

  15. Cattykool
    Member
    Posted 6 years ago #

    Hi

    Go to Manage ->Pages
    Edit you home page
    Click on the Discussion box and uncheck the comments.
    That is how to get rid of the comments.

    Have a look at the other boxes to find the other stuff.

    Hope that helps.

  16. matthew123
    Member
    Posted 6 years ago #

    Thx for your quick reply but thats not exactly what I'm looking for. That's just disable the comments but I want to make in like "real webpage without blogging things such as commnet div, tags, etc.
    But anyway thx again for your quick reply.

  17. i-BOB
    Member
    Posted 6 years ago #

    @ ynotweb: YOU RULE! 5 stars for that simple and functional method.

  18. Zeromage
    Member
    Posted 6 years ago #

    Hi,
    I was able to make a static homepage and a blog page using the methods described above. I named my static homepage "welcome." My problem is as follows, these are my links across the top of my page:

    Home About Us Blog Forums FAQ Welcome

    is there any way to hide the "welcome" link, since it is redundant given that there is already a "Home" link.

  19. moshu
    Member
    Posted 6 years ago #

    Zeromag, don't double post!
    I responded to your other post (in another thread) giving the solution.

    (btw, you are wrong: the "home" link is redundant... if anything)

  20. mpm
    Member
    Posted 6 years ago #

    I have my WP in a seperate directory (not root).

    I have a specific Page from my WP that I wish to display (comments and all) in my sites index page at root. (ie. outside the wp installation).

    How do I achieve this?

  21. Josh Fialkoff
    Member
    Posted 6 years ago #

    Hi,

    I have a Website built on WP (www.dawnnelson.org).

    Now, I want to add a blog to the site.

    I followed the advice above and write a page with the URL http://www.dawnnelson.org/blog/.

    I then went to Reading preferences and set the static home page to http://www.dawnnelson.org and the blog home page to http://www.dawnnelson.org/blog.

    The static front page works fine, but when I go to http://www.dawnnelson.org/blog, I get a 404 error, even though I can see that I have a page published at http://www.dawnnelson.org/blog.

    I would definitely appreciate any help!

    Thanks,
    Josh

  22. revolutionfrance
    Member
    Posted 6 years ago #

    Hey...had the same problem, but this post helped
    http://wordpress.org/support/topic/165588

  23. paultwo
    Member
    Posted 6 years ago #

    Ok, figured this one out for you.

    @nooozeguy Specifically to address your issue. All you need to do at this point is go change your permalink structure. Add /blog/ before whatever your current permalink structure is and Viola!

    Hope that helps. If you have a question or need help with that feel free to contact me via the footer on paultwo.net

    My example:

    Static Home Page - http://www.paultwo.net
    Blog Page - http://www.paultwo.net/blog/

  24. Josh Fialkoff
    Member
    Posted 6 years ago #

    I added /blog/ to the permalink structure... but I get a 404 error when I go to domain.org/blog.

    Do I need to do something else to set up my blog's home page?

    Thanks,
    Josh

Topic Closed

This topic has been closed to new replies.

About this Topic