mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-03 01:39:24 +02:00
This commit is contained in:
parent
d1378979b2
commit
c7657791fe
2 changed files with 11 additions and 3 deletions
|
@ -457,8 +457,12 @@ class Layout extends PluginAbstract
|
|||
|
||||
static function getCategorySelect($name, $selected = "", $id = "", $class = "")
|
||||
{
|
||||
$rows = Category::getAllCategories(true, false);
|
||||
array_multisort(array_column($rows, 'hierarchyAndName'), SORT_ASC, $rows);
|
||||
$parentsOnly = @$_GET['parentsOnly'];
|
||||
unset($_GET['parentsOnly']);
|
||||
$rows = Category::getAllCategories(true, false);
|
||||
$_GET['parentsOnly'] = $parentsOnly ;
|
||||
//var_dump($rows);exit;
|
||||
//array_multisort(array_column($rows, 'hierarchyAndName'), SORT_ASC, $rows);
|
||||
$cats = array();
|
||||
foreach ($rows as $value) {
|
||||
$cats[$value['id']] = htmlentities("<i class='{$value['iconClass']}'></i> " . $value['hierarchyAndName']);
|
||||
|
|
|
@ -109,7 +109,11 @@
|
|||
<div class="<?php echo $divCol2; ?>">
|
||||
<?php
|
||||
if ($showCategory) {
|
||||
$categories = Category::getAllCategories(true, false);
|
||||
$parentsOnly = @$_GET['parentsOnly'];
|
||||
unset($_GET['parentsOnly']);
|
||||
$categories = Category::getAllCategories(true, false);
|
||||
$_GET['parentsOnly'] = $parentsOnly ;
|
||||
//var_dump($categories);exit;
|
||||
?>
|
||||
<label class="control-label" for="inputCategory" ><?php echo __("Category"); ?></label>
|
||||
<select class="form-control last" id="inputCategory" required>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue