Different description text for different categories – Help needed

Community Forums Forums Design Tips and Tricks Different description text for different categories – Help needed

This topic is: not resolved

This topic contains 11 replies, has 2 voices, and was last updated by  Kate 1 year, 7 months ago.

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #2858

    Kate
    Participant
    Post count: 4

    Hey All,

    I desperately want to customize my blog but I am experiencing problems doing this.

    I am using the Minimum theme and I want to add different category description text before the footer line of my blog for the different categories of the site.

    For example I want to use one text for this category http://www.thecupcakeuniverse.com/category/birthday-cupcakes/

    Another text for http://www.thecupcakeuniverse.com/category/cute-baby-shower-cupcakes/

    I need this texts to appear above the footer grey line ( the line above the copyright text) after all the posts.

    I have searched the old forum for a solution and from what I get this zone is probably above_footer and instructions must be specified for every category, but I am not sure if I am right and I am not able to figure it how to do it.

    I will greatly appreciate if you help me with this problem of mine.

    I want to thank you in advance for your precious time and kind cooperation!

    Thank you!

    #2866

    SoZo
    Moderator
    Post count: 1573

    See this tutorial for instructions on adding a new sidebar down there. You’ll want to use the genesis_before_footer hook. Then you can place text widgets into the new sidebar and use widget logic to control which widget shows up for each category.


    John “Nicolas Flamel” Wright | SoZo’s design| John Wright Photography

    #2872

    Kate
    Participant
    Post count: 4

    Dear SoZo,

    Thank you very, very much for your kind and prompt reply!!

    I will immediately check the info.

    Thanks! :)

     

    #2912

    Kate
    Participant
    Post count: 4

    Hi All,

    I have used the information so kindly pointed by SoZo and of course thank to NickTheGeek for preparing the guide.

    With the information in the guide I have managed to add the new widget as follows:

    genesis_register_sidebar( array(
    ‘id’ => ‘after-products-text’,
    ‘name’ => ‘After Products Text’,
    ‘description’ => ‘This is a sidebar that goes after the products lists.’,
    ) );

    add_action( ‘genesis_before_footer’, ‘child_after_products_text_sidebar’ );
    /** Loads a new sidebar after the products lists */
    function child_after_products_text_sidebar() {

    echo ‘<div class=”after-products-text”>’;
    dynamic_sidebar( ‘after-products-text’ );
    echo ‘</div>’;

    }

     

    Can you please be so kind and prompt me how I can set the logic for the different texts to show in the different categories without the help of a plugin, but with a code instead.

    Thank you in advance for the cooperation!

     

    #2921

    SoZo
    Moderator
    Post count: 1573

    This should help


    John “Nicolas Flamel” Wright | SoZo’s design| John Wright Photography

    #2924

    Kate
    Participant
    Post count: 4

    Dear Sozo,

    Thank you very much for your continued support.

    I have one last question about the conditional tags.

    Where should I put the code for them.

    The code I have provided in my previous post I have included into the Functions.php section.

    Should I put the conditional tags code in the Functions.php section also, or in another section.

    I am using the Minimum them and I have :

    - Functions.php

    - Home.php

    -Page_landing.php

    - Style.css

    Please excuse me for my question that I realize can be a little lame, but I am not experienced with coding, so I hope to get your kind understanding on the matter.

    Thank you!

    #2932

    SoZo
    Moderator
    Post count: 1573

    Actually you should use the plugin to enter the conditional tag


    John “Nicolas Flamel” Wright | SoZo’s design| John Wright Photography

    #2995

    Kate
    Participant
    Post count: 4

    Dear Sozo,

    Thank you very much for your kind cooperation.

    You help is much appreciated!!

    From what I get from the info you have been so kind to provide there is a way to add them without plugin.

    Can someone help with this?

    And once again thanks SoZo!!

    #2996

    SoZo
    Moderator
    Post count: 1573

    Use the plugin. Otherwise you have to add a lot of different sidebars.


    John “Nicolas Flamel” Wright | SoZo’s design| John Wright Photography

    #2997

    Kate
    Participant
    Post count: 4

    Thanks for the prompt reply!

    I only need 7 texts, and I have added 7 text fields in the widget area that I have created using the tutorial that Nick has set up.

    Now I only need the code for the logic which text to be used for which category.

     

    is_home and is_category ()

    If I can see an example how this needs to be st I will replace the info and of course in which file to include the code that is my biggest problem.

    Thanks!

    #2998

    SoZo
    Moderator
    Post count: 1573

    And is written “&&” so is_home() && is_category()

    There are more syntax examples aplenty here.


    John “Nicolas Flamel” Wright | SoZo’s design| John Wright Photography

    #3087

    Kate
    Participant
    Post count: 4

    Thank you SoZo!! :)

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

The topic ‘Different description text for different categories – Help needed’ is closed to new replies.