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


PHP MUtil_Html::urlString方法代码示例

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


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

示例1: calculateReturnUrl

 /**
  * Returns the full url Gems should forward to after survey completion.
  *
  * This fix allows multiple sites with multiple url's to share a single
  * installation.
  *
  * @return string
  */
 protected function calculateReturnUrl()
 {
     $currentUri = $this->util->getCurrentURI();
     /*
             // Referrer would be powerful when someone is usng multiple windows, but
             // the loop does not always provide a correct referrer.
             $referrer   = $_SERVER["HTTP_REFERER"];
     
             // If a referrer was specified and that referral is from the current site, then use it
             // as it is more dependable when the user has multiple windows open on the application.
             if ($referrer && (0 == strncasecmp($referrer, $currentUri, strlen($currentUri)))) {
                 return $referrer;
                 // \MUtil_Echo::track($referrer);
             } // */
     // Use the survey return if available.
     $surveyReturn = $this->loader->getCurrentUser()->getSurveyReturn();
     if ($surveyReturn) {
         // Do not show the base url as it is in $currentUri
         $surveyReturn['NoBase'] = true;
         // Add route reset to prevet the current parameters to be
         // added to the url.
         $surveyReturn['RouteReset'] = true;
         // \MUtil_Echo::track($currentUri, \MUtil_Html::urlString($surveyReturn));
         return $currentUri . \MUtil_Html::urlString($surveyReturn);
     }
     // Ultimate backup solution for return
     return $currentUri . '/ask/forward/' . \MUtil_Model::REQUEST_ID . '/' . urlencode($this->getTokenId());
 }
开发者ID:GemsTracker,项目名称:gemstracker-library,代码行数:36,代码来源:Token.php


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