Need help? Check out our Support site, then


Categories widget not working

  1. The categories widget is working on inside pages, but not on the home page.

    No: http://mainedoenews.net/
    Yes: http://mainedoenews.net/2011/04/05/improvement-schools/

    Any tips on on what to look for to resolve this issue?

    -Jay

    The blog I need help with is mainedoenews.net.

  2. @collier
    I’m sorry but that blog is not a free blog from and being free hosted by wordpress.COM so we cannot help you with it. WordPress.COM blogs and wordpress.org installs operate on different code. The correct support forum to get support for that blog is here > http://wordpress.ORG/support

    For more clarity please read the sticky post at the head of this forum or the summary provided by Staff in the support documentation.
    http://en.forums.wordpress.com/topic/please-read-me-first-before-posting?replies=1
    For more on the difference: http://support.wordpress.com/com-vs-org/

  3. Actually, it IS on WordPress.com.

    What makes you think it isn't?

    -Jay

  4. The category pulldown on the main page is working for me.

    Just FYI, you are not allowed to hide the standard wordpress.com/theme footer information here at wordpress.COM, and you risk having your blog suspended if you do.

  5. The footer links are missing. Here at wordpress.com we are not allowed to hide or remove the footer link to the theme designer and the link to wordpress.com via CSS editing. http://en.forums.wordpress.com/topic/changes-to-blog-footer?replies=12#post-556783

    Also the dropdown on my navigation bar only works sporadically so I could not click Blog Info and determine that it was a wordpress.com blog. In any event I apologize.

    The bottom line here is you need to go to Staff > http://en.support.wordpress.com/contact/

  6. Please ignore my bottom line statement above as the categories on your front and on internal pages are working for me. I'm using Firefox 3.6.16. Please try this troubleshooting:

    If that doesn't work then please tell us which browser and version of it you are using.

  7. Thank you so much for the heads-up about the colophon links! I returned them immediately!

    We saw this problem with Firefox 4 RC, Safari 5.04, and IE 8 (including fully reset browsers) and will check others. I was flummoxed because the drop-down worked in one setting and not another.

    I'll keep investigating and report back here.

  8. I think I have a lead.

    In order to provide a different set of widgets on our home page and on the inside pages, we hid the Coraline theme's Feature widgets on home and hid the Primary/Secondary widgets on others, based on body classes.

    My experience is that most widgets can be used multiple times on one page, which, in essence, is what we're doing.

    However, I did a W3C validation which indicated a duplicated ID. Perhaps the Categories widget can't be used twice? This issue does not appear with any other multiple widgets.

    Is this a known issue? Is there anything that can be done by end-users to resolve the issue?

  9. Put a couple of them into the sidebar and take a look at the source code. I would think they would have unique IDs, but then again since they are identical duplicates, perhaps not.

    I looked in Safari 5.0.4 and saw then one on the home page just fine, but here lately I've had a couple instances where people were seeing something messed up with 5.0.4 and I was not with the same version of the browser. Perhaps I'm blessed, or my copy of Safari is blessed.

    Of course with computer, who can say?

  10. The Search and Categories widgets both appear twice on each page (one of each hidden by CSS) and, as you can see below, they use the same ID, which defeats validation.

    http://bit.ly/gWcLBc

    The other widgets, however, are fine.

    I wonder if there is any way to resolve this?

  11. I certainly can't think of any since they have identical IDs.

  12. At one point, I remember discussion about allowing multiple instances of widgets by providing different IDs, but I haven't been able to find reference to that.

    Am I searching for the wrong terms, or are these two widgets permanently restricted to one instance only?

  13. Let me do some playing around here. I was looking at the source code on your site and I might have an idea.

  14. I was a little confused, but I think I got it straight what you want.

    I just activated Coraline on one of my test blogs, added some widgets, and except for the "meta" widget, all widget types end up with a unique ID. See example below.

    <li id="categories-10"...
    <li id="linkcat-24632793"...
    <li id="text-3"...
    <li id="archives-3"...

    So, if you wanted only the categories and text widget to show on a page, you would use target the specific page ID and then do a display none for the widgets you did not want to show on that page as below (example page ID 3).

    .page-id-3 #linkcat-24632793, .page-id-3 #archives-3 {
    display:none;
    }

    If on page with id 4 you only wanted the categories and archives to show, then you would do this.

    .page-id-4 #linkcat-24632793, .page-id-4 #text-3 {
    display:none;
    }

    For the home page, you would use something like this.

    .home #linkcat-24632793, .home #text-3 {
    display:none;
    }`

    Do note that with categories widgets, since they show exactly the same thing, there is no reason to have multiples. With the links widget, you can have multiples since you can in the widget itself set it to only show the links under certain categories.

  15. I forgot a backtick on that last bit of code.

    .home #linkcat-24632793, .home #text-3 {
    display:none;
    }
  16. I just thought of something. You could have multiples of category widgets if say you wanted the one on the home page to be a dropdown list, and the on on other pages to by the full list (not dropdown). Then you could use two and target them as you wanted.

  17. Unfortunately, it's the form elements in the Search and Categories widgets that have the duplicated IDs ...

    '<input type="submit" id="searchsubmit" value="Search" />'
    '<select name='cat' id='cat' class='postform' >'

    ... so, no matter whether I show or hide in CSS, the HTML doesn't validate.

    http://bit.ly/gWcLBc

    I think the only real solution would be if the widgets generated classes rather than IDs for the form elements. Then, they could be styled individually without validation problems.

    And, you are right that I could use the full category list. It's just very long ;)

    In the meantime, I've thought of another work around. I am using one set of widgets on the home page right column and a different set on inside pages because I wanted to not show recent posts on the home page (that would be duplicative).

    However, I'm willing to have the exact same right column show up in both places. So, I can use the secondary area throughout and leave out the feature/crown altogether.

    Not the best solution, but it works. Since I've been able to do EVERYTHING else I've wanted with .COM hosting, that's only a small price to pay.

    Thank you, @thesacredpath, for taking the time to engage on this somewhat subtle issue. You prompted me to think through multiple solutions. That is one reason I am a WordPress evangelist: the community!

    Best,

    -Jay

  18. Classes style a "class" of elements. IDs style individual elements.

    I guess I'm not understanding where the issue is.

  19. You are welcome by the way although I was not able to be of much help.

  20. IDs and classes can both be used on any element, but whereas a class can be used with a number of elements, an ID can't be repeated twice in one file.

    Since IDs are generated to style form elements within the Search and Categories widgets, they can only be used once on a page; having two ID instances breaks W3C validation and also messes us JavaScript, which is why the drop-downs were working inconsistently on the second instance.

  21. You actually were helpful, in that the discussion about this issue prompted me to investigate possible causes I'd not have found alone.

    So, thanks again!

Topic Closed

This topic has been closed to new replies.

About this Topic