当前位置: 首页>>代码示例>>PHP>>正文


PHP Box::setIcon方法代码示例

本文整理汇总了PHP中Box::setIcon方法的典型用法代码示例。如果您正苦于以下问题:PHP Box::setIcon方法的具体用法?PHP Box::setIcon怎么用?PHP Box::setIcon使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Box的用法示例。


在下文中一共展示了Box::setIcon方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: menu

 /**
  * Build the menu.
  *  Additional options that have been set are added to the menu.
  */
 function menu()
 {
     $menubox = new Box("Menu");
     $menubox->setIcon("menu-item.gif");
     foreach ($this->menuOptions as $options) {
         if (isset($options[2])) {
             $menubox->addOption($options[0], $options[1], $options[2]);
         } else {
             $menubox->addOption($options[0], $options[1]);
         }
     }
     return $menubox->generate();
 }
开发者ID:biow0lf,项目名称:evedev-kb,代码行数:17,代码来源:awards.php

示例2: menu

 /**
  * Generates the menu for the user
  * @return string
  */
 public static function menu()
 {
     $box = new Box('User');
     $box->setIcon('menu-item.gif');
     if (!user::loggedin()) {
         $box->addOption('link', 'Login', edkURI::build(array('a', 'login', true)));
         $box->addOption('link', 'Register', edkURI::build(array('a', 'register', true)));
     } else {
         if (user::get('usr_pilot_id')) {
             $plt = Pilot::getByID((int) user::get('usr_pilot_id'));
             $box->addOption('link', $plt->getName(), edkURI::build(array('a', 'pilot_detail', true), array('plt_id', $plt->getID(), true)));
         }
         $box->addOption('link', 'Logout', edkURI::build(array('a', 'logout', true)));
     }
     event::call('user_menu_create', $box);
     return $box->generate();
 }
开发者ID:biow0lf,项目名称:evedev-kb,代码行数:21,代码来源:class.user.php

示例3: genAdminMenu

 /**
  * Generate admin menu.
  * 
  * @return string HTML for a menu of admin links.
  */
 public static function genAdminMenu()
 {
     // sort the menu alphabetically
     ksort(self::$data);
     // create a standardbox to print all links into
     $menubox = new Box('Options');
     $menubox->setIcon('menu-item.gif');
     foreach (self::$data as $field => $subfields) {
         $menubox->addOption('caption', $field);
         foreach ($subfields as $subfield => $array) {
             // if this subfield has no options then it is a category
             if (!is_array($array)) {
                 $menubox->addOption('link', $subfield, $array);
                 continue;
             }
             // we're not a category, make it clickable
             $menubox->addOption('link', $subfield, edkURI::build(array(array('a', 'admin', true), array('field', urlencode($field), true), array('sub', urlencode($subfield), true))));
         }
         $lastfield = $field;
     }
     return $menubox->generate();
 }
开发者ID:biow0lf,项目名称:evedev-kb,代码行数:27,代码来源:class.options.php

示例4: menu

 /**
  * Build the menu.
  *
  *  Add all preset options to the menu.
  *
  * @return string HTML for the menus
  */
 function menu()
 {
     $menubox = new Box("Menu");
     $menubox->setIcon("menu-item.gif");
     foreach ($this->menuOptions as $options) {
         call_user_func_array(array($menubox, 'addOption'), $options);
         //			if(isset($options[2]))
         //				$menubox->addOption($options[0],$options[1], $options[2]);
         //			else
         //				$menubox->addOption($options[0],$options[1]);
     }
     return $menubox->generate();
 }
开发者ID:biow0lf,项目名称:evedev-kb,代码行数:20,代码来源:kill_detail.php

示例5: menuSetup

 /**
  * Set up the menu.
  *
  *  Additional options that have been set are added to the menu.
  */
 function menuSetup()
 {
     $args = array();
     if ($this->all_external_id) {
         $args[] = array('all_ext_id', $this->all_external_id, true);
     } else {
         $args[] = array('all_id', $this->all_id, true);
     }
     $menubox = new Box("Menu");
     $menubox->setIcon("menu-item.gif");
     $this->addMenuItem("caption", "Kills & losses");
     $this->addMenuItem("link", "Recent activity", edkURI::build($args));
     $this->addMenuItem("link", "Historical activity", edkURI::build($args, array('view', 'history', true)));
     $this->addMenuItem("link", "Kills", edkURI::build($args, array('view', 'kills', true)));
     $this->addMenuItem("link", "Losses", edkURI::build($args, array('view', 'losses', true)));
     $this->addMenuItem("caption", "Corp statistics");
     $this->addMenuItem("link", "Corp List", edkURI::build($args, array('view', 'corp_list', true)));
     $this->addMenuItem("link", "Top killers", edkURI::build($args, array('view', 'corp_kills', true)));
     $this->addMenuItem("link", "Top losers", edkURI::build($args, array('view', 'corp_losses', true)));
     $this->addMenuItem("link", "Destroyed ships", edkURI::build($args, array('view', 'corp_kills_class', true)));
     $this->addMenuItem("link", "Lost ships", edkURI::build($args, array('view', 'corp_losses_class', true)));
     $this->addMenuItem("caption", "Pilot statistics");
     $this->addMenuItem("link", "Top killers", edkURI::build($args, array('view', 'pilot_kills', true)));
     if (config::get('kill_points')) {
         $this->addMenuItem('link', "Top scorers", edkURI::build($args, array('view', 'pilot_scores', true)));
     }
     $this->addMenuItem("link", "Top losers", edkURI::build($args, array('view', 'pilot_losses', true)));
     $this->addMenuItem("link", "Destroyed ships", edkURI::build($args, array('view', 'kills_class', true)));
     $this->addMenuItem("link", "Lost ships", edkURI::build($args, array('view', 'losses_class', true)));
     $this->addMenuItem("caption", "Global statistics");
     $this->addMenuItem("link", "Ships & weapons", edkURI::build($args, array('view', 'ships_weapons', true)));
     $this->addMenuItem("link", "Most violent systems", edkURI::build($args, array('view', 'violent_systems', true)));
 }
开发者ID:biow0lf,项目名称:evedev-kb,代码行数:38,代码来源:alliance_detail.php


注:本文中的Box::setIcon方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。