Post Title Links or Dropdown at Top of Category Archives

Community Forums Forums Design Tips and Tricks Post Title Links or Dropdown at Top of Category Archives

This topic is: not resolved

This topic contains 4 replies, has 2 voices, and was last updated by  Au Coeur 6 months, 2 weeks ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #92530

    Au Coeur
    Participant
    Post count: 102

    I have a client who is using category archives to organize a lot of posts on their website. They would like all post titles in each category to be available at the top of the category archive in either a list or a dropdown, so that any individual post can be found without scrolling. I know I can do this by adding a widget area to the top of each category and using a plugin like Featured Posts Amplified, but there are a lot of categories and I would love to set this up as a feature that is automatically available should the client create more categories in the future. Can anyone recommend a plugin? Or does anyone have an idea about how I might utilize Bill’s display post shortcodes to and add this into the functions file?


    Mother. Web & Graphic Designer. Lactation Consultant. Blogging about how it all fits together, most recently from northern Colorado. Visit my blog or my design site.

    http://enjoyrhinebeck.com/new/
    #100458

    Susan
    Moderator
    Post count: 9426

    As you posted this a while ago, I hope you got your issue resolved. If not, please let me know, and I will take a look (or escalate if I cannot help).

    If it is resolved, please mark it resolved, so that the thread can be closed.

    Thanks!


    Susan @ Graphically Designing I offer theme customizations I tweet!
    I’ve taken up the challenge! – help me answer some of the unanswered posts

    #100503

    Au Coeur
    Participant
    Post count: 102

    Nope, never got it resolved.


    Mother. Web & Graphic Designer. Lactation Consultant. Blogging about how it all fits together, most recently from northern Colorado. Visit my blog or my design site.

    #100504

    Au Coeur
    Participant
    Post count: 102

    …I also never spent a lot of time trying to figure it out with Bill’s plugin.


    Mother. Web & Graphic Designer. Lactation Consultant. Blogging about how it all fits together, most recently from northern Colorado. Visit my blog or my design site.

    #105224

    Au Coeur
    Participant
    Post count: 102

    Hi Susan,

    I am working on this now. The problem I seem to have is related to the current category generation. I am trying to use this code:

    //* Add List Above Category Archives
    function post_list_on_category_archive() {
    if ( is_category() ) {
        	echo '<div class="before-category">';
    	echo do_shortcode( '[display-posts posts_per_page="-1" order="ASC" orderby="title" columns="2" category="$category_id"]' );
    	$category_id = get_query_var( 'cat' );
    	echo '</div>';
    }
    
    };
    
    add_action('genesis_before_content', 'post_list_on_category_archive');

    If I remove “category=…” the short code will display as expected. But for some reason adding in category=”$category_id” returns nothing where the shortcode should be.

    Thoughts?


    Mother. Web & Graphic Designer. Lactation Consultant. Blogging about how it all fits together, most recently from northern Colorado. Visit my blog or my design site.

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.