linking pages to categories (cant figure out)

Discussion in 'WordPress' started by deepanshusethi, Dec 23, 2010.

  1. #1
    Hello. Please tell me how do I make a page display when I click on a specific category ? SInce homepage has both page menu and category menu, is there a way that I go to a page whe i click on category and that page does not appear on page menu. Since i want a lot of static pages and i want to use my category menu for users to see those static pages, please tell me a way so that linked pages in categories dont appear on page menu of the theme...thanks
     
    deepanshusethi, Dec 23, 2010 IP
  2. bob25

    bob25 Well-Known Member

    Messages:
    1,519
    Likes Received:
    12
    Best Answers:
    0
    Trophy Points:
    128
    #2
    Not sure if I understand correctly, but when you're creating the page go to "Page Attributes" on the right (below Publish/Update) and select the "Parent" page (category)
     
    bob25, Dec 23, 2010 IP
  3. deepanshusethi

    deepanshusethi Peon

    Messages:
    141
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    no u got me wrong. i will explain in detail

    There are 2 navigation bars, page navigation bar for displaying static pages and category navigation bar, which displays posts from new to old...

    Now what I want to do ..

    I want to use my category navigation bar as the main bar since its bigger and mmore attractive than page navigation bar which seems to be somewhat hidden at the top.

    Now i want to display some static pages when my users click on a particular category (just like when they see on a page). So what I m thinking is that i make a page with static content and somehow don't display it in the page navigation bar but instead when my user clicks on a particular category, he sees that static pppage..

    SO how do i link a page to a category without having the page to display in the page navigation bar ? Please help . :confused:
     
    deepanshusethi, Dec 23, 2010 IP
  4. bkurious

    bkurious Well-Known Member

    Messages:
    43
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    106
    #4
    I think I get what you're after.

    The best way to do this is to manipulate the PHP code. Go into Appearance (side navigation) --> Editor and find the header.php file or wherever your navigation is coded.

    From here, find the PHP code for displaying the Pages and copy it to your clipboard. The code will look something like this:

    Then find the code for your Category navigation, like this:

    Paste the Pages code over this Category code. Then delete the pages code if want your pages not to display on your site.

    Your pages links should be styled like your categories. And your other pages navigation should disappear.

    ==================================

    If you rather use plugins, download the Page Links To plugin. You can use this plugin to link pages to categories). Then use the Exclude Pages plugin to remove the page from your navigation.

    Page Links To plugin: http://wordpress(dot)org/extend/plugins/page-links-to/
    Exclude Pages plugin: http://wordpress(dot)org/extend/plugins/exclude-pages/

    ==================================

    I am not quite sure how this will all work out. Hope I helped!
     
    bkurious, Dec 23, 2010 IP
  5. deepanshusethi

    deepanshusethi Peon

    Messages:
    141
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Thanks a ton man :) ....plugins will be fine for a newbie like me.

    But i cant work out this fully....i mean this theme is basically that when i click on a particluar page it redirects me to somewhere else (suppose category)....but this is opposute to what i want ....i want if i click the category name it redirects me to page..please can u help :(
     
    deepanshusethi, Dec 23, 2010 IP
  6. deepanshusethi

    deepanshusethi Peon

    Messages:
    141
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #6
    sorry maybe i put the title wrong, i realised it now..i mean linking categories to pages and not vice versa.....sorry
     
    deepanshusethi, Dec 23, 2010 IP
  7. robaid

    robaid Member

    Messages:
    126
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    35
    #7
    You could edit your php file for categories in order to do that, or just simply create your own static menu that links to some pages with the names of the categories.
     
    robaid, Dec 23, 2010 IP
  8. deepanshusethi

    deepanshusethi Peon

    Messages:
    141
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #8
    what do i need to edit exactly please explain in detail...i m new to wordpress :( i just somehow want to see static content on clicking on categories :(
     
    deepanshusethi, Dec 23, 2010 IP
  9. robaid

    robaid Member

    Messages:
    126
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    35
    #9
    Since you are new to WP, and I guess you're new to PHP programming as well, better (although not good solution) is to make a static menu where you would link to pages named "some category-page" and exclude that page from menu with pages by using Exclude pages plugin. It's not an elegant solution, but it'll do what you desire.

    Where would you link (show) category lists if you want to serve static pages instead of them?
     
    robaid, Dec 23, 2010 IP
  10. deepanshusethi

    deepanshusethi Peon

    Messages:
    141
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #10
    actually my static page menu is not too attractive and it maybe missed by user's eyes since it is located at extreme top ...i m planning to use this theme http://www.freshthemes.com/demo/weekly/ ...is there a way that i can bring the page menu just below the category menu.....or if not is there a way that i can make page navigation bar more highlighted big so that it catches attention ? if yes please suggest how ....thanks a lot for taking out time for replying me :)
     
    deepanshusethi, Dec 23, 2010 IP
  11. robaid

    robaid Member

    Messages:
    126
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    35
    #11
    Some changes in theme CSS file regarding menu size or ID name (weekly/wp-content/themes/weekly/style.css) and small changes in index.php regarding menu placement (weekly/wp-content/themes/weekly/index.php) should do the job.

    Since it is not a free theme, I couldn't look into index.php for more help.
     
    robaid, Dec 23, 2010 IP
  12. deepanshusethi

    deepanshusethi Peon

    Messages:
    141
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #12
    If i give u the download link of the theme, will u be able to tell me then ? i m really sorry if I m irritating u . :'(
     
    deepanshusethi, Dec 23, 2010 IP
  13. deepanshusethi

    deepanshusethi Peon

    Messages:
    141
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #13
    deepanshusethi, Dec 23, 2010 IP
  14. bkurious

    bkurious Well-Known Member

    Messages:
    43
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    106
    #14
    I just sent you a PM
     
    bkurious, Dec 23, 2010 IP
  15. deepanshusethi

    deepanshusethi Peon

    Messages:
    141
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #15
    replied :D
     
    deepanshusethi, Dec 23, 2010 IP
  16. robaid

    robaid Member

    Messages:
    126
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    35
    #16
    Sorry for my late reply, even I do sleep sometimes :)

    If bkurious didn't already help ya, you could PM me the code of your index.php (if you are allowed due to terms you agreed to).
     
    robaid, Dec 24, 2010 IP
    deepanshusethi likes this.
  17. deepanshusethi

    deepanshusethi Peon

    Messages:
    141
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #17
    yes he helped me ...thanks for offering man :)
     
    deepanshusethi, Dec 24, 2010 IP