Forums

Design/Organization Question (11 posts)

  1. yk
    Member
    Posted 4 years ago #

    I'm having some problems wrapping my head around how to organize my site. I would like to have two separate Pages. One that contains normal blog entries. And the other that contains chapters to a book - entered as blog entries also.

    Any ideas on the best approach? Do i create two categories instead and then filter depending on which template is used? Idealy I would like /blog and /book - I'm just not sure how to properly set this up.

    First time user here - any help would be greatly appreciated. Thanks in advance.

  2. moshu
    Member
    Posted 4 years ago #

    For "normal blog entries" youi don't need Pages. (Pages is a special feature in WP).
    Two categories, with different category templates could be one solution.
    Or, the blog happening as "normal" and put the Book on Pages and subPages (=chapters?).

    I cannot say more - would need 10 times more info for an advice...

  3. yk
    Member
    Posted 4 years ago #

    Thanks for the reply moshu.
    Ideally I would like to have two main categories. One for blogs and one for book chapters. In the main page I'm going to try to exclude any posts and just have an intro text (pretty sure this can be done). Then I'd like to show either blog or book categories depending on what page you're on. That's where I'm a bit lost. I'd like to show book categories on the homepage and blog categories on the blog page. I've gone through the codex a decent amount but also wanted to ask here.

  4. moshu
    Member
    Posted 4 years ago #

    Do you have WP installed already? Because if not, it will be very difficult to explain "theoretically" what can you do and how... (and what can't)

  5. yk
    Member
    Posted 4 years ago #

    I do have it installed already and have started to begin customizing the default template to suit my design.

  6. moshu
    Member
    Posted 4 years ago #

    Unless you are very good at it, I'd advise: modify anything but default.

    Back to categories. First you said you want 2 categories: blog and book. Now you are talking about book categories and book categories - in plural. Does it mean you want to have X number of sub-categories under the 2 main categories?
    The "intro" page you can solve by using the home.php template file (usually it has to be created). See Template_Hierarchy
    The blog and the book section can de very different even in design - by using the Category_Templates.

  7. yk
    Member
    Posted 4 years ago #

    Excellent. Thanks very much. I'm quite familiar with php and css. I was just having an issue with the proper approach to architecture.
    I plan to use the blog and book category as two parents with multiple sub-categories, yup. So two separate entrance pages with different content.
    Do you recommend hardcoding links to the two category templates?

  8. moshu
    Member
    Posted 4 years ago #

    No, WP "recognizes" them if they are in the theme folder and uses them to display the category they belong to. E.g. category-2.php will be used to display the cat with ID# 2.

  9. yk
    Member
    Posted 4 years ago #

    Right. That I understand. But I'm not sure if I can use the two parent categories as "top navigation" and the sub-categories as "left navigation". If that makes sense.

    I'm trying to run a high level nav across the top of the site and then the sub categories within the sidebar depending on which top level nav category you picked. This is where I'm getting hung up.

  10. moshu
    Member
    Posted 4 years ago #

    At the top just use a template tag with parameters that doesn't display children (or, if hardcoding NEVER link to the template file, but to the category link, e.g. ?cat=2); and in the sidebar use something like Template_Tags/wp_list_cats to display only child_of=3.
    (everything is in the Codex)

  11. yk
    Member
    Posted 4 years ago #

    Thanks a million moshu.

Topic Closed

This topic has been closed to new replies.

About this Topic