[wp-trac] [WordPress Trac] #40827: WP Regular post categories bug also affects Woocommerce products categories

WordPress Trac noreply at wordpress.org
Sat May 20 11:12:21 UTC 2017


#40827: WP Regular post categories bug also affects Woocommerce products categories
--------------------------------+-----------------------------
 Reporter:  raykaii             |      Owner:
     Type:  defect (bug)        |     Status:  new
 Priority:  normal              |  Milestone:  Awaiting Review
Component:  Menus               |    Version:  4.7.5
 Severity:  normal              |   Keywords:
  Focuses:  ui, administration  |
--------------------------------+-----------------------------
 HI,

 i have found a bug that is causing me lot of frustration when doing menus
 using categories.

 There is a bug with the categories nesting/child categories on the menu
 create page. When having many sub-nesting/child categories when the
 category list has over 50 nested categories and the category small menu
 auto creates a second page then it messes up the categories nesting.

 This is hard to explain.

 On this 1st image, is when some sub-nesting/child categories fit on one
 page. this is good.
 Note:I had to remove the menu box height to show what i mean.
 [[Image(https://image.ibb.co/eTgfav/nesting_on_one_page.jpg)]]

 but when a sub-nesting/child categories have too many sub-nesting/child
 (about 50) that gets chopped on 2 or more pages then the tree of the
 categories then the tree bugs.
 [[Image(https://image.ibb.co/jjwfav/bug.jpg)]]


 This is Tab/page:2
 It brakes the tree here too plus it adds the rest of the sub-nesting/child
 categories at the bottom of the page why? it should be at the top as its
 the continuing of tab/page 1 of the categories.

 [[Image(https://image.ibb.co/hDiUJF/page_2.jpg)]]


 This bugs also affects Woocommerce products categories as we sometimes
 need many sub products categories.

 i 1st found this bug when doing a menu with Woocommerce products
 categories i opened a bug report here:
 [https://github.com/woocommerce/woocommerce/issues/13040]

 here or some screen shots of that bug ticket.

 woocommerce Product Categories tree.jpg:

 [[Image(https://image.ibb.co/hNZmyF/6db82992_e7fd_11e6_8090_5631505dd16d.jpg)]]

 [[Image(https://image.ibb.co/ckkFsa/762fb7fc_e7fd_11e6_81a2_7e00aa1b8432.jpg)]]

 [[Image(https://image.ibb.co/fyVFsa/a496612c_e7fd_11e6_8c69_028e8ea6891d.jpg)]]


 After talking with some Woocommerce devs they told me this was a WP core
 bug.

 i note "It looks like the problem has to do with the nesting / child
 categories. The second page starts with the categories that are top-level
 and their children. Then at the end it has the miscellaneous categories
 whose parents are on page 1."

 " But it's not something we should be fixing as it's generated and
 rendered by WP core (all hierarchical categories output in the same way).
 We don't control that code."

 "If that's broken because of WP core's handling (looks like it is), yeah I
 think we should raise it."

 So this is why i am opening this ticket with WP.
 '''BUG:'''

 How to replicate this bug with WP.
 create a root Categorie with 2 or more Parent Categories in it.
 then add say 50 subcategories in a parent so on the create menu page the
 category menu box splits the subcategories on a second page. '''Note:'''
 it needs to split the subcategories. if the subcategories fits on one page
 it will not work)

 EXP:

 {{{
 root cat 1
 root cat 2
 root cat 3
           - Parent Lv 1
           -- Parent lv 2
           ---  Parent lv 3 - category 01
           --- (ADD 50 other category in this parent)
 }}}

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


More information about the wp-trac mailing list