mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-16 22:42:16 +00:00
replaces wrong quatations in the menu items if the link_onclick array key is defined
This commit is contained in:
@@ -248,7 +248,8 @@ class LvMenu extends FHCAPI_Controller
|
||||
|
||||
// Addons Menu Logic
|
||||
// ##########################################################################################
|
||||
$params = [
|
||||
|
||||
$params = [
|
||||
'user'=>$user,
|
||||
'lvid'=>$lvid,
|
||||
'studiensemester_kurzbz'=>$studiensemester_kurzbz,
|
||||
@@ -271,12 +272,17 @@ class LvMenu extends FHCAPI_Controller
|
||||
$params
|
||||
);
|
||||
|
||||
|
||||
// Menu sortieren
|
||||
// ##########################################################################################
|
||||
|
||||
foreach ($menu as $key => $row){
|
||||
$pos[$key] = $row['position'];
|
||||
// replace the path to the icon
|
||||
$menu[$key]['icon'] = base_url(str_replace("../../..","",$row['icon']));
|
||||
// replace the quatations in the link_onclick
|
||||
if(array_key_exists("link_onclick",$menu[$key])){
|
||||
$menu[$key]['link_onclick'] = str_replace("\"","'",$menu[$key]['link_onclick']);
|
||||
}
|
||||
}
|
||||
|
||||
array_multisort($pos, SORT_ASC, SORT_NUMERIC, $menu);
|
||||
|
||||
Reference in New Issue
Block a user