0

if anyone can figure this out, thanks a million!

I wanted to have my wp install at root level where the homepage displays excerpts of latest blogs but I still wanted the top navigation to point to a "blog" page www.mydomain.com/blog which displays the full latest blog (and allows comments).

I thought I was being clever by creating a new Page Template just for this blog page - I copy/pasted the single post code into this template and created a static page called blog using that template. My permalink structure ensures if would be found like so www.mydomain.com/blog.

It all works beautifully except no comments functionality - I tried googling and trying a few things but comments_template('', true) and variations at various points in the page didnt do the trick. Best I can do is: comments_popup_link('No Comments | Click to Comment', '1 Comment | Click to Comment', '% Comments | Click to Comment');

Please smart people, come to my rescue :)

Thanks!

1 Answer 1

1

Create a page and make it your front page.

Visit the Administration > Settings > Reading panel and under Front page displays, you can choose to set any (published) Page or Posts Page as the Front Page.

Create a page called 'blog', and choose this as your posts page in the reading panel.

Hope this helps.

Sign up to request clarification or add additional context in comments.

5 Comments

This is a lot better solution than the one used by the OP. This way you won't have a problem with the comments, and you can always change where your blog is located or what your front page is if you need to.
Thanks for your help - I tried your suggestion and again, it didn't display comments. It seems like even though its a "page" it's not admitting to being one. I went into comment-template.php and commented out the lines:
woops....if ( !(is_single() || is_page() || $withcomments) || empty($post) ) return;
sorry about multi posting - it works when that line is removed - why might the page not be returning true to is_page() and how can I find out what it is? Thanks!
OK - solved this with a simple wp_reset_query(); Thanks for all your help and I will structure the blog as you suggest....cheers!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.