WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Drop down menu? (9 posts)

  1. Raginwolf
    Member
    Posted 5 years ago #

    According to CSS-Tricks.com WordPress can dynamically create a child page by setting page parent in write page. Well...It only added another page for me. What am I doing wrong?
    Please help and advise.
    Thank you.
    Sincerely,
    David Sellers
    http://www.roadkillerkustoms.com

    Help...I am just the Airbrush artist! lol

  2. Dgold
    Member
    Posted 5 years ago #

    Check in your WP Admin > Manage > Categories, and see if it actually did (in fact) create a Child Page.

    It's possible that the CSS and code of your homepage theme, does not show child pages differently from parent pages. They may be styled the same. I guess that you are looking for them to be indented. more, right.

    This is just one guess

  3. Raginwolf
    Member
    Posted 5 years ago #

    Actually Chris Coyier from CSS-Tricks has a video that shows WordPress can create dynamically drop down menus from the menu bar that include child pages and subs etc...
    I followed his lead...and all I get is an "added" regular page.

    Hmmm??? He mentioned nothing about the themes css...pretty much said that is the way it is done in WordPress.

    Thank you though...I will have a look at the css code...I know a little about it.

  4. Dgold
    Member
    Posted 5 years ago #

    Ahh. Yes there is a way to do that (I have not watched the video). There is a simple Template Tag for it,
    http://codex.wordpress.org/Template_Tags/wp_dropdown_categories

    I think you pretty much can use this example code, from the Codex (which is the online Documentation of WP)

    <li id="categories">
     <h2><?php _e('Categories:'); ?></h2>
       <form action="<?php bloginfo('url'); ?>" method="get">
       <?php wp_dropdown_categories('show_count=1&hierarchical=1'); ?>
       <input type="submit" name="submit" value="view" />
       </form>
    </li>

    Just put that code in your theme's sidebar.php

    Make sure you make a back-up of your theme files before you mess around with editing stuff like that. That way you can go-back, in case it doesn't turn out like you expect. Enjoy!

  5. Raginwolf
    Member
    Posted 5 years ago #

    Great! I thought maybe either I missed something or Chris forgot to mention??? lol
    I greatly appreciate your help on this...well...here goes.
    Thank you.
    David

  6. Raginwolf
    Member
    Posted 5 years ago #

    Uh oh...I just thought of something...
    Will this work in the header.php? For the Menu across the top?
    That is how Chris showed it being done...hmmmm?
    I'm searching some more. Not familiar enough at all with CSS yet to tweak it myself for header.php.

    Still...Thank you
    This will be handy.

  7. Raginwolf
    Member
    Posted 5 years ago #

    bump need dropdown for header...hmmm...will this work for that? Ya know...instead of sidebar categories...

  8. Raginwolf
    Member
    Posted 5 years ago #

    In dark_classic template I removed the code from header.php. Used the multi-navigational plugin...pasted some code BACK where I cut the code in header.php...ready to roll. :)
    Thank you all.
    Sincerely,
    David

  9. dennymathews
    Member
    Posted 5 years ago #

    Raginwolf ~

    You mentioned the video that you saw in CSS-Tricks.com. Which video is it? And how did you resolve the parent-child drop menu problem? I'm having the same problem with my theme.

    Thank you,

    Denny.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.