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


PHP XenForo_Router::resolveActionWithIntegerParam方法代码示例

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


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

示例1: match

 /**
  *
  * @see XenForo_Route_PrefixAdmin_AddOns::match()
  */
 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $parts = explode('/', $routePath, 3);
     switch ($parts[0]) {
         case 'languages':
             $parts = array_slice($parts, 1);
             $routePath = implode('/', $parts);
             $action = $router->resolveActionWithIntegerParam($routePath, $request, 'language_id');
             return $router->getRouteMatch('XenForo_ControllerAdmin_Language', $action, 'languages');
         case 'phrases':
             $parts = array_slice($parts, 1);
             $routePath = implode('/', $parts);
             return $router->getRouteMatch('XenForo_ControllerAdmin_Phrase', $routePath, 'phrases');
     }
     if (count($parts) > 1) {
         switch ($parts[1]) {
             case 'languages':
                 $action = $router->resolveActionWithStringParam($routePath, $request, 'addon_id');
                 $parts = array_slice($parts, 2);
                 $routePath = implode('/', $parts);
                 $action = $router->resolveActionWithIntegerParam($routePath, $request, 'language_id');
                 return $router->getRouteMatch('XenForo_ControllerAdmin_Language', $action, 'languages');
             case 'phrases':
                 $action = $router->resolveActionWithStringParam($routePath, $request, 'addon_id');
                 $parts = array_slice($parts, 2);
                 $routePath = implode('/', $parts);
                 return $router->getRouteMatch('XenForo_ControllerAdmin_Phrase', $routePath, 'phrases');
         }
     }
     return parent::match($routePath, $request, $router);
 }
开发者ID:ThemeHouse-XF,项目名称:Phrases,代码行数:35,代码来源:AddOns.php

示例2: match

 /**
  * Match a specific route for an already matched prefix.
  *
  * @see XenForo_Route_Interface::match()
  */
 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     if (preg_match('#^action/(.*)$#i', $routePath, $match)) {
         $action = 'action' . $router->resolveActionWithIntegerParam($match[1], $request, 'warning_action_id');
     } else {
         $action = $router->resolveActionWithIntegerParam($routePath, $request, 'warning_definition_id');
     }
     return $router->getRouteMatch('XenForo_ControllerAdmin_Warning', $action, 'userWarnings');
 }
开发者ID:namgiangle90,项目名称:tokyobaito,代码行数:14,代码来源:Warnings.php

示例3: match

 /**
  * Match a specific route for an already matched prefix.
  *
  * @see XenForo_Route_Interface::match()
  */
 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $parts = explode('/', $routePath, 2);
     $action = $parts[0];
     if (isset($parts[1])) {
         switch ($action) {
             case 'super':
                 $action .= $router->resolveActionWithIntegerParam($parts[1], $request, 'user_id');
                 break;
             case 'content':
                 $action .= $router->resolveActionWithIntegerParam($parts[1], $request, 'moderator_id');
                 break;
         }
     }
     return $router->getRouteMatch('XenForo_ControllerAdmin_Moderator', $action, 'moderators');
 }
开发者ID:Sywooch,项目名称:forums,代码行数:21,代码来源:Moderators.php

示例4: match

 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $action = $router->resolveActionWithIntegerParam($routePath, $request, 'id');
     $routeMatch = $router->getRouteMatch('Dark_TaigaChat_ControllerPublic_TaigaChat', $action, 'taigachat', $routePath);
     //$routeMatch->setResponseType('jsonText');
     return $routeMatch;
 }
开发者ID:Sywooch,项目名称:forums,代码行数:7,代码来源:TaigaChat.php

示例5: match

 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $components = explode('/', $routePath);
     $subPrefix = strtolower(array_shift($components));
     $controllerName = '';
     $action = '';
     $intParams = 'page_id';
     $strParams = '';
     $slice = false;
     switch ($subPrefix) {
         case 'special':
             if (!empty($components[1]) && ($components[0] == 'edit-template' || $components[0] == 'delete-template')) {
                 unset($components[1]);
             }
             $controllerName = '_Special';
             $slice = true;
             break;
         case 'archive':
             $controllerName = '_Archive';
             $intParams = 'history_id';
             $slice = true;
             break;
         default:
             $strParams = 'page_slug';
     }
     $routePathAction = implode('/', array_slice($slice ? $components : explode('/', $routePath), 0, 2)) . '/';
     $routePathAction = str_replace('//', '/', $routePathAction);
     if ($strParams) {
         $action = $router->resolveActionWithStringParam($routePathAction, $request, $strParams);
     } else {
         $action = $router->resolveActionWithIntegerParam($routePathAction, $request, $intParams);
     }
     $action = $router->resolveActionAsPageNumber($action, $request);
     return $router->getRouteMatch('EWRcarta_ControllerPublic_Wiki' . $controllerName, $action, 'wiki', $routePath);
 }
开发者ID:Sywooch,项目名称:forums,代码行数:35,代码来源:Wiki.php

示例6: match

 /**
  * Match a specific route for an already matched prefix.
  *
  * @see XenForo_Route_Interface::match()
  */
 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     if (preg_match('#^auto/(.*)$#i', $routePath, $match)) {
         $action = 'auto' . $router->resolveActionWithIntegerParam($match[1], $request, 'auto_warning_id');
         return $router->getRouteMatch('XenForo_ControllerAdmin_Warning', $action, 'userWarnings');
     }
     return parent::match($routePath, $request, $router);
 }
开发者ID:ThemeHouse-XF,项目名称:AutoWarning,代码行数:13,代码来源:Warnings.php

示例7: match

 /**
  * Match a specific route for an already matched prefix.
  *
  * @see XenForo_Route_Interface::match()
  */
 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $action = $router->getSubComponentAction($this->_subComponents, $routePath, $request, $controller);
     if ($action === false) {
         $action = $router->resolveActionWithIntegerParam($routePath, $request, 'profile_post_id');
     }
     return $router->getRouteMatch('XenForo_ControllerPublic_ProfilePost', $action, 'members');
 }
开发者ID:darkearl,项目名称:projectT122015,代码行数:13,代码来源:ProfilePosts.php

示例8: match

 /**
  * Match a specific route for an already matched prefix.
  *
  * @see XenForo_Route_Interface::match()
  */
 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $controller = 'ThreePointStudio_CustomMarkupForUser_ControllerAdmin_CMFU';
     $action = $router->getSubComponentAction($this->_subComponents, $routePath, $request, $controller);
     if ($action === false) {
         $action = $router->resolveActionWithIntegerParam($routePath, $request, 'preset_id');
     }
     return $router->getRouteMatch($controller, $action, 'users', '3ps-cmfu/');
 }
开发者ID:iversia,项目名称:3ps_cmfu,代码行数:14,代码来源:CMFU.php

示例9: match

 /**
  * Match a specific route for an already matched prefix.
  *
  * @see XenForo_Route_Interface::match()
  */
 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $action = $router->resolveActionWithIntegerParam($routePath, $request, 'node_id');
     if (!class_exists('XFCP_ThemeHouse_SocialGroups_ControllerAdmin_SocialCategory', false)) {
         $createClass = XenForo_Application::resolveDynamicClass('XenForo_ControllerAdmin_Forum', 'controller');
         eval('class XFCP_ThemeHouse_SocialGroups_ControllerAdmin_SocialCategory extends ' . $createClass . ' {}');
     }
     return $router->getRouteMatch('ThemeHouse_SocialGroups_ControllerAdmin_SocialCategory', $action, 'nodeTree');
 }
开发者ID:AndroidOS,项目名称:SocialGroups,代码行数:14,代码来源:SocialCategories.php

示例10: match

 /**
  * Match a specific route for an already matched prefix.
  *
  * @see XenForo_Route_Interface::match()
  */
 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $controller = 'XenGallery_ControllerPublic_Redirects_XenMedio';
     $action = $router->getSubComponentAction($this->_subComponents, $routePath, $request, $controller);
     if ($action == false) {
         $action = $router->resolveActionWithIntegerParam($routePath, $request, 'media_id');
     }
     return $router->getRouteMatch($controller, $action);
 }
开发者ID:VoDongMy,项目名称:xenforo-laravel5.1,代码行数:14,代码来源:XenMedio.php

示例11: match

 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     if (in_array($routePath, array('add', 'save'))) {
         $action = $routePath;
     } else {
         $action = $router->resolveActionWithIntegerParam($routePath, $request, 'log_id');
     }
     return $router->getRouteMatch('bdApi_ControllerAdmin_Log', $action, 'bdApi');
 }
开发者ID:billyprice1,项目名称:bdApi,代码行数:9,代码来源:Log.php

示例12: match

 /**
  * @param $routePath
  * @param Zend_Controller_Request_Http $request
  * @param XenForo_Router $router
  * @return false|XenForo_RouteMatch
  */
 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $controller = 'sonnb_XenGallery_ControllerAdmin_XenGallery';
     $action = $router->getSubComponentAction($this->_subComponents, $routePath, $request, $controller);
     if ($action === false) {
         $action = $router->resolveActionWithIntegerParam($routePath, $request, '');
     }
     return $router->getRouteMatch($controller, $action, 'sonnb_xengallery');
 }
开发者ID:Sywooch,项目名称:forums,代码行数:15,代码来源:XenGallery.php

示例13: match

 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $action = $router->resolveActionWithIntegerParam($routePath, $request, 'tag_id');
     $majorSection = 'Tinhte_XenTag_Tag';
     if (empty($action) or strtolower($action) == 'index') {
         $majorSection = 'threadsPosts';
     }
     return $router->getRouteMatch('Tinhte_XenTag_ControllerAdmin_Tag', $action, $majorSection);
 }
开发者ID:Sywooch,项目名称:forums,代码行数:9,代码来源:Tag.php

示例14: match

 /**
  * Match a specific route for an already matched prefix.
  *
  * @see XenForo_Route_Interface::match()
  */
 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $controller = 'XenResource_ControllerPublic_Resource';
     $action = $router->getSubComponentAction($this->_subComponents, $routePath, $request, $controller);
     if ($action === false) {
         $action = $router->resolveActionWithIntegerParam($routePath, $request, 'resource_id');
     }
     return $router->getRouteMatch($controller, $action, 'resources');
 }
开发者ID:Sywooch,项目名称:forums,代码行数:14,代码来源:Resources.php

示例15: match

 public function match($routePath, Zend_Controller_Request_Http $request, XenForo_Router $router)
 {
     $subcomponents = $this->_getSubcomponents();
     $defaultController = $subcomponents['categories']['controller'];
     $action = $router->getSubComponentAction($subcomponents, $routePath, $request, $defaultController);
     if ($action === false) {
         $action = $router->resolveActionWithIntegerParam($routePath, $request, 'portalItem_id');
     }
     return $router->getRouteMatch($defaultController, $action, 'portal');
 }
开发者ID:NixFifty,项目名称:XenForo-SimplePortal,代码行数:10,代码来源:Lpmanage.php


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