Make WordPress Core

Opened 17 years ago

Closed 16 years ago

#10333 closed defect (bug) (fixed)

Pages in Search results with the_category() shows default category

Reported by: pavelevap Owned by:
Priority: normal Milestone: 3.0
Component: Template Version:
Severity: normal Keywords: needs-patch
Cc: Focuses:

Description

When using the_category() in Search results (search.php) in template, pages are shown with default category. That is nonsense, no category should be displayed. Tested with default theme, only search for something which contains default page, then you will see results with this page in category: Uncategorized.

Change History (4)

#1 @pavelevap
17 years ago

  • Cc pavelevap@… added

#2 @ryan
17 years ago

  • Milestone 2.9 → 3.0

#3 @nacin
17 years ago

  • Keywords needs-patch added

This has new implications in 3.0. Some well-placed is_object_in_taxonomy() checks should do the trick.

#4 @markjaquith
16 years ago

  • Resolution → fixed
  • Status new → closed

(In [14660]) Do not show dummy default category output when calling the_category on a post_type that does not support the category taxonomy (like pages). Fix TwentyTen theme to not display wrapping text if there are no categories. fixes #10333

Note: See TracTickets for help on using tickets.