• docholliday

    (@docholliday)


    I’m setting up my site, http://www.lifecrafting.net, and I’m having problems. I found instructions to get my blog to appear at http://www.lifecrafting.net/blog off the wordpress faq, but the instructions appear not to work. I’ve posted the instructions below.

    So, I created my Blog.php file in wordpad, pasted the text in, and uploaded it to the wordpress/themes directory. I have 2.1.2 so I don’t need the home.php file.

    I go into my dashboard, create a page called “Blog”, but when I click on “page template”, my new file, which should be displayed as “blog”, is not available.

    What am I doing wrong? Thanks.

    These are the instructions:

    Making your blog appear in a non-root folder

    Suppose you have WordPress running at http://example.com/. Suppose further that you want your blog to be located at http://example.com/blog/ and that you want other pages to be available at http://example.com/page1/.

    The first thing you will want to do is to create a home page. You can do this by creating home.php in your theme directory. Next, create a blog template. The easiest way to do this is to create a file named blog.php with the following contents in your theme directory:

    <?php
    /*
    Template Name: Blog
    */
    // Which page of the blog are we on?
    $paged = get_query_var(‘paged’);
    query_posts(‘cat=-0&paged=’.$paged);
    load_template(TEMPLATEPATH . ‘/index.php’); //loads index
    ?>

    Log into WordPress and create a page named “Blog” with template “blog”. You’re done. The one last thing you will want to do is to update your permalinks structure to begin with “/blog/”, ie, “/blog/%year%/%monthnum%/%postname%/”. Now you have a WordPress-managed CMS with a unique front page and logically-structured blog content.

    As noted above, the home.php file is not needed in versions 2.1+. If both the blog.php and home.php files are deployed in 2.1+ they will conflict and cause the blog.php templated page to appear blank.

Viewing 14 replies - 1 through 14 (of 14 total)
  • Samuel B

    (@samboll)

    uploaded it to the wordpress/themes directory

    path should be /wp-content/themes/yourtheme/blog.php

    Also, if you want to have your files in /blog and access your site and pages at the root, you need to modify the index file:
    http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory

    doggybag

    (@doggybag)

    Just a thought ….

    # Copy the index.php and .htaccess files from the WordPress directory into the root directory of your site (Blog address).

    # Login to the new location. It might now be http://example.com/wordpress/wp-admin/

    Does it make a difference to the search engines that the site address is http://example.com/wordpress/wp-admin/

    and not http://www.example.com/wordpress/wp-admin/ ?

    The reason I ask is that I did have a 6/10 GOOGLE rating with the site http://www.barganews.com but since installing wordpress into the root it changes http://www.barganews.com over to http://barganews.com/index.php and I have since dropped right off the google page

    ciao
    db

    rudolf45

    (@rudolf45)

    I have 2.1.2

    So, then why do you have to go through all this misery that was written for WP versions BEFORE 2.1.x when you couldn’t set up a home page from the admin panel?
    Get rid of everything you did till now and just login to your admin > Options > Reading… and select the Page you want as frontpage. Done.

    Thread Starter docholliday

    (@docholliday)

    I’ve created a page called main, which I set to be the front page. I then created a page called blog, which I set to display posts.

    When I type in my url, I get put immediately to my blog.

    How do I get main to display first?

    rudolf45

    (@rudolf45)

    What I meant above: in 2.1.x you do NOT need to create a file blog.php and all that stuff what you described in your previous posts. All those instructions are not valid for 2.1.x.
    So, delete all those files, you don’t need them!

    Thread Starter docholliday

    (@docholliday)

    I’ve deleted all those files. Infact, I’ve reuploaded the theme, so I know everything is normal.

    So, I followed your directions, logged on as an admin, and set a page called “main” to be the front page. I created a page called blog to display my posts.

    Yet, when I go to my route directory, http://www.lifecrafting.net , I still see my blog when I should see a blank “main” page.

    If you want to see what I’m talking about, notice how this wordpress blog sends you to a mainpage at the route directory, and requires you to go to /blog to get to the blog.

    That’s what I want.

    rudolf45

    (@rudolf45)

    Except that “example” site’s main/home page is NOT a WP page…

    rudolf45

    (@rudolf45)

    Another thought: what if you switch to another theme, like default or classic – does the “frontpage” thing work?

    Thread Starter docholliday

    (@docholliday)

    I tried classic, and the blog is still showing up on the front page.

    Just a thought: Under Options > General, there is a box to input wordpress address and blog address. I tried changing them to lifecrafting.net and lifecrafting.net/blog respectively, but this causes my pages to not load. Something else I can do with this?

    Thread Starter docholliday

    (@docholliday)

    Bump

    rudolf45

    (@rudolf45)

    Definitely you shouldn’t mess around with those two URI values!
    On the other hand I am running out of ideas, sorry. I can’t reproduce your error: even with a blank Page designated for frontpage I got the desired result – it show up as an emtpy “entry” page.

    Thread Starter docholliday

    (@docholliday)

    Ok. Well, if I wanted to try deleting wordpress and starting over, would you recommend installing wordpress in lifecrafting.net or lifecrafting.net/blog? Could I still get wordpress to control lifecrafting.net if it was placed in a subdirectory?

    Any other ideas?

    Thanks.

    rudolf45

    (@rudolf45)

    Could I still get wordpress to control lifecrafting.net if it was placed in a subdirectory?
    As far as I know – the answer is no, you can’t.

    charle97

    (@charle97)

    Could I still get wordpress to control lifecrafting.net if it was placed in a subdirectory?
    As far as I know – the answer is no, you can’t.

    wrong. you can. samboll provided the howto to do what you want yesterday. http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘Help with getting the first to be the root directory and th blog to be root/blog’ is closed to new replies.