WordPress.org

Ready to get started?Download WordPress

Forums

Dynamic Widgets
Problem with multiple assigned categories (4 posts)

  1. pixelschumi
    Member
    Posted 3 years ago #

    Hey guys,

    I'm using the Dynamic widget - Plugin in my website and it is great. But I have a little problem with it when I assign more than one category to a post.

    For example:
    1. I have two categories - News and Projects
    2. In News I have widget A and in Projects a widget B
    3. If now a Post is assigned to both categories both widgets will be shown in the widget-area

    This happens on the categorie-page and the single-page and depends on the post. All other posts which belong to only one category are fine.

    I'm not sure whether I've made a mistake. Perhaps someone has the same problem and could fix it.

    http://wordpress.org/extend/plugins/dynamic-widgets/

  2. Qurl
    Member
    Plugin Author

    Posted 3 years ago #

    Hi pixelschumi,

    What exactly do you want to achieve when a post is assigned to both categories? Cause what you describe now is exactly how it works:
    - Dynamic Widgets finds the post belongs to News -> Shows Widget A
    - Dynamic Widgets finds the post belongs (also) to Projects -> Shows Widget B

    I guess however as you made a forum post here the result is not what you expected.

  3. pixelschumi
    Member
    Posted 3 years ago #

    Hi qurl,

    thanks for the fast reply :-)

    I thought the plugin is based on the categories. What I want to achieve is the following. I have a category with projects and one with news. Both have different templates. The Projects-loop shows the complete content, the News-loop shows only the excerpt. My Idea was to have the complete project-content under Projects and its excerpt under News. Additionally, I have different widgets for each category. The result is, if this post is active all widgets are shown.

    But with your explanation I see problem. If the plugin depends on the post I have to change my layout slightly.

  4. Qurl
    Member
    Plugin Author

    Posted 3 years ago #

    Hi pixelschumi,

    When you set the categories under the Single Posts section the category is a property of the post. When you set the category under the Category section, the post is a property of the category.

    So, when you want Widget A to be displayed for category News, you should set for Widget A everything to No, except for Roles and Dates. Check the News category under the Single Post section and check the News category under the Category section. Same story for widget B, except the other category of course. ;)

    When you have a post which have both News and Project, then both widgets gets displayed in the single post page. However, it shouldn't display both widgets in the category page, only the widget belonging to the category.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic