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


PHP cmsFramework::constructRoute方法代码示例

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


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

示例1: initialize

 function initialize($params = array())
 {
     if (count($params) > 0) {
         foreach ($params as $key => $val) {
             $this->{$key} = $val;
         }
     }
     # Construct new route
     if (isset($this->passedArgs) && is_null($this->base_url)) {
         $this->base_url = cmsFramework::constructRoute($this->passedArgs, array('page', 'limit', 'lang'));
     }
 }
开发者ID:atikahmed,项目名称:joomla-probid,代码行数:12,代码来源:paginator.php

示例2: generateFormSelect

 function generateFormSelect($orderingList, $selected, $attributes)
 {
     # Construct new route
     $new_route = cmsFramework::constructRoute($this->passedArgs, array('order', 'page'));
     $selectList = array();
     foreach ($orderingList as $value => $text) {
         $selectList[] = array('value' => cmsFramework::route($new_route . '/order' . _PARAM_CHAR . $value), 'text' => $text);
     }
     $selected = cmsFramework::route($new_route . '/order' . _PARAM_CHAR . $selected);
     return $this->Form->select('order', $selectList, $selected, $attributes);
 }
开发者ID:atikahmed,项目名称:joomla-probid,代码行数:11,代码来源:jreviews.php

示例3: listingsFeed

 function listingsFeed($title = '', $attributes = array())
 {
     $base_url = rtrim(cmsFramework::constructRoute($this->passedArgs), '/') . '/action:xml/';
     $title = sprintf(__t("%s listing feeds", true), $title);
     if (isset($attributes['return_url'])) {
         $base_url = cmsFramework::route($base_url);
         return $base_url;
     } else {
         $attributes = array_merge(array('title' => $title, 'class' => 'jr_feedListings'), $attributes);
         return $this->Html->link('', $base_url, $attributes);
     }
 }
开发者ID:atikahmed,项目名称:joomla-probid,代码行数:12,代码来源:routes.php

示例4: generateFormSelect

 function generateFormSelect($orderingList, $selected, $attributes)
 {
     # Construct new route
     $new_route = cmsFramework::constructRoute($this->passedArgs, array('lang', 'order', 'page'));
     if (Sanitize::getInt($this->params, 'page', 1) == 1 && preg_match('/^(index.php\\?option=com_jreviews&Itemid=[0-9]+)(&url=menu\\/)$/i', $new_route, $matches)) {
         // Remove menu segment from url if page 1 and it' a menu
         $new_route_page_1 = $matches[1];
     }
     $selectList = array();
     foreach ($orderingList as $value => $text) {
         $default_order = Sanitize::getString($this->params, 'default_order');
         // Default order takes user back to the first page
         if ($value == $default_order) {
             $selectList[] = array('value' => cmsFramework::route($new_route_page_1), 'text' => $text);
         } else {
             $selectList[] = array('value' => cmsFramework::route($new_route . '/order' . _PARAM_CHAR . $value), 'text' => $text);
         }
     }
     if ($selected == $default_order) {
         $selected = cmsFramework::route($new_route_page_1);
     } else {
         $selected = cmsFramework::route($new_route . '/order' . _PARAM_CHAR . $selected);
     }
     return $this->Form->select('order', $selectList, $selected, $attributes);
 }
开发者ID:atikahmed,项目名称:joomla-probid,代码行数:25,代码来源:jreviews.php


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