[wp-trac] [WordPress Trac] #30883: Duplicate post_class() for different categories

WordPress Trac noreply at wordpress.org
Fri Jan 2 00:24:11 UTC 2015


#30883: Duplicate post_class() for different categories
-------------------------+-------------------------------------------------
 Reporter:               |      Owner:
  SergeyBiryukov         |     Status:  new
     Type:  defect       |  Milestone:  4.2
  (bug)                  |    Version:
 Priority:  normal       |   Keywords:  good-first-bug needs-patch needs-
Component:  Posts, Post  |  unit-tests
  Types                  |
 Severity:  normal       |
  Focuses:               |
-------------------------+-------------------------------------------------
 1. Create two categories, "Первая рубрика" and "Вторая рубрика". They will
 have the following slugs:
 {{{
 %d0%b2%d1%82%d0%be%d1%80%d0%b0%d1%8f-%d1%80%d1%83%d0%b1%d1%80%d0%b8%d0%ba%d0%b0
 %d0%bf%d0%b5%d1%80%d0%b2%d0%b0%d1%8f-%d1%80%d1%83%d0%b1%d1%80%d0%b8%d0%ba%d0%b0
 }}}
 2. Create a post in each category.
 3. Both posts will have a `category--` class.

 `sanitize_html_class()` uses a fallback value (term ID) if the resulting
 string is empty. It should do the same if the resulting string only
 contains hyphens.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/30883>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list