コード例 #1
0
ファイル: ewmenu.php プロジェクト: elliecm/MadisonandRayne
 function AddMenuItem($id, $text, $url, $parentid, $src, $allowed = TRUE)
 {
     $item = new cMenuItem($id, $text, $url, $parentid, $src, $allowed);
     if (!MenuItem_Adding($item)) {
         return;
     }
     if ($item->ParentId < 0) {
         $this->AddItem($item);
     } else {
         if ($oParentMenu =& $this->FindItem($item->ParentId)) {
             $oParentMenu->AddItem($item);
         }
     }
 }
コード例 #2
0
ファイル: menu.php プロジェクト: asmirasurianie/xaminer-v10
 function AddMenuItem($id, $text, $url, $parentid, $src, $target, $allowed = TRUE)
 {
     $item = new crMenuItem($id, $text, $url, $parentid, $src, $target, $allowed);
     // Fire MenuItem_Adding event
     if (function_exists("MenuItem_Adding") && !MenuItem_Adding($item)) {
         return;
     }
     if ($item->ParentId < 0) {
         $this->AddItem($item);
     } else {
         if ($oParentMenu =& $this->FindItem($item->ParentId)) {
             $oParentMenu->AddItem($item);
         }
     }
 }
コード例 #3
0
ファイル: ewshared12.php プロジェクト: NoSympathy/Dashboard
 function AddMenuItem($id, $name, $text, $url, $parentid = -1, $src = "", $allowed = TRUE, $grouptitle = FALSE, $customurl = FALSE)
 {
     if (is_int($url) && is_bool($src)) {
         // For backward compatibility (without the $name argument)
         list($text, $url, $parentid, $src, $allowed, $grouptitle, $customurl) = array($name, $text, $url, $parentid, $src, $allowed, $grouptitle);
         $name = "mi_" . $id;
     }
     $item = new cMenuItem($id, $name, $text, $url, $parentid, $src, $allowed, $grouptitle, $customurl);
     $item->Parent =& $this;
     // Fire MenuItem_Adding event
     if (function_exists("MenuItem_Adding") && !MenuItem_Adding($item)) {
         return;
     }
     if ($item->ParentId < 0) {
         $this->AddItem($item);
     } else {
         if ($oParentMenu =& $this->FindItem($item->ParentId)) {
             $oParentMenu->AddItem($item, $this->IsMobile);
         }
     }
 }
コード例 #4
0
ファイル: ewshared10.php プロジェクト: scintes/sistemas
 function AddMenuItem($id, $text, $url, $parentid = -1, $src = "", $allowed = TRUE, $grouptitle = FALSE, $customurl = FALSE)
 {
     $item = new cMenuItem($id, $text, $url, $parentid, $src, $allowed, $grouptitle, $customurl);
     // Fire MenuItem_Adding event
     if (function_exists("MenuItem_Adding") && !MenuItem_Adding($item)) {
         return;
     }
     if ($item->ParentId < 0) {
         $this->AddItem($item);
     } else {
         if ($oParentMenu =& $this->FindItem($item->ParentId)) {
             $oParentMenu->AddItem($item, $this->IsMobile);
         }
     }
 }