Create subcategories while creating a category
bleekk opened this issue · comments
When you create a category you have the you have the option to create subcategories all at once.
You see it if you scroll to the bottom of the site where you create a category.
If you try to create more then one subcategory only the first one will be created.
I looked at the code /admin/category.php and at line 142 you have this
$sizeof = count(XoopsRequest::getString('scname', '', 'POST'));
this will always return a 1
I changed this line to $sizeof = count(XoopsRequest::getArray('scname', array(), 'POST'));
and now everything works fine. Can someone confirm that the code is correct
This is already fixed in my repository: https://github.com/mambax7/publisher/blob/master/admin/category.php