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


PHP Ibos::getPathOfAlias方法代码示例

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


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

示例1: update

 public static function update($cacheName = "")
 {
     $updateList = empty($cacheName) ? array() : (is_array($cacheName) ? $cacheName : array($cacheName));
     if (!$updateList) {
         $cacheDir = Ibos::getPathOfAlias(self::CACHE_ALIAS);
         $cacheDirHandle = dir($cacheDir);
         while ($entry = $cacheDirHandle->read()) {
             $isProviderFile = preg_match("/^([\\_\\w]+)CacheProvider\\.php\$/", $entry, $matches) && substr($entry, -4) == ".php" && is_file($cacheDir . "/" . $entry);
             if (!in_array($entry, array(".", "..")) && $isProviderFile) {
                 $class = basename($matches[0], ".php");
                 if (class_exists($class)) {
                     Ibos::app()->attachBehavior("onUpdateCache", array("class" => self::CACHE_ALIAS . "." . $class));
                 }
             }
         }
     } else {
         foreach ($updateList as $entry) {
             $owner = ucfirst($entry) . "CacheProvider";
             if (class_exists($owner)) {
                 Ibos::app()->attachBehavior("onUpdateCache", array("class" => self::CACHE_ALIAS . "." . $owner));
             }
         }
     }
     if (Ibos::app()->hasEventHandler("onUpdateCache")) {
         Ibos::app()->raiseEvent("onUpdateCache", new CEvent(Ibos::app()));
     }
 }
开发者ID:AxelPanda,项目名称:ibos,代码行数:27,代码来源:CacheUtil.php

示例2: init

 protected function init()
 {
     Ibos::setPathOfAlias("engineDriver", Ibos::getPathOfAlias("ext.enginedriver.sae"));
     $alias = Ibos::getPathOfAlias("engineDriver");
     $classes = array("CMemCache" => $alias . "/caching/CMemCache.php", "CDbCommand" => $alias . "/db/CDbCommand.php", "CDbConnection" => $alias . "/db/CDbConnection.php");
     Ibos::$classMap = CMap::mergeArray(Ibos::$classMap, $classes);
     Ibos::import("engineDriver.*");
 }
开发者ID:AxelPanda,项目名称:ibos,代码行数:8,代码来源:SaeEngine.php

示例3: init

 public function init()
 {
     $widgetPath = Ibos::getPathOfAlias($this->widgetPath);
     Ibos::setPathOfAlias("wfwidget", $widgetPath);
 }
开发者ID:AxelPanda,项目名称:ibos,代码行数:5,代码来源:IWWfBase.php

示例4: getModulePath

 public static function getModulePath()
 {
     static $path;
     if (!$path) {
         $path = Ibos::getPathOfAlias("application") . self::DS . self::MODULE_ALIAS . self::DS;
     }
     return $path;
 }
开发者ID:AxelPanda,项目名称:ibos,代码行数:8,代码来源:ModuleUtil.php

示例5: parseTemplate

 private function parseTemplate($_data)
 {
     $user = User::model()->fetchByUid($_data["uid"]);
     $_data["data"] = unserialize($_data["feeddata"]);
     $var = $_data["data"];
     if (!empty($var["attach_id"])) {
         $var["attachInfo"] = AttachUtil::getAttach($var["attach_id"]);
         $attachUrl = FileUtil::getAttachUrl();
         foreach ($var["attachInfo"] as $ak => $av) {
             $_attach = array("attach_id" => $av["aid"], "attach_name" => $av["filename"], "attach_url" => FileUtil::fileName($attachUrl . "/" . $av["attachment"]), "extension" => StringUtil::getFileExt($av["filename"]), "size" => $av["filesize"]);
             if ($_data["type"] == "postimage") {
                 $_attach["attach_small"] = WbCommonUtil::getThumbImageUrl($av, WbConst::ALBUM_DISPLAY_WIDTH, WbConst::ALBUM_DISPLAY_HEIGHT);
                 $_attach["attach_middle"] = WbCommonUtil::getThumbImageUrl($av, WbConst::WEIBO_DISPLAY_WIDTH, WbConst::WEIBO_DISPLAY_HEIGHT);
             }
             $var["attachInfo"][$ak] = $_attach;
         }
     }
     $var["uid"] = $_data["uid"];
     $var["actor"] = "<a href='{$user["space_url"]}' data-toggle='usercard' data-param=\"uid={$user["uid"]}\">{$user["realname"]}</a>";
     $var["actor_uid"] = $user["uid"];
     $var["actor_uname"] = $user["realname"];
     $var["feedid"] = $_data["feedid"];
     if (!empty($_data["rowid"])) {
         empty($_data["table"]) && ($_data["table"] = "feed");
         $var["sourceInfo"] = Source::getSourceInfo($_data["table"], $_data["rowid"], false, $_data["module"]);
     } else {
         $var["sourceInfo"] = null;
     }
     $feedTemplateAlias = "application.modules.message.config.feed.{$_data["type"]}Feed";
     $file = Ibos::getPathOfAlias($feedTemplateAlias);
     if (!file_exists($file . ".php")) {
         $feedTemplateAlias = "application.modules.message.config.feed.postFeed";
     }
     $feedXmlContent = Ibos::app()->getController()->renderPartial($feedTemplateAlias, $var, true);
     $s = simplexml_load_string($feedXmlContent);
     if (!$s) {
         return false;
     }
     $result = $s->xpath("//feed[@type='" . StringUtil::filterCleanHtml($_data["type"]) . "']");
     $actions = (array) $result[0]->feedAttr;
     $return["content"] = $var["content"];
     if (isset($var["attach_id"])) {
         $return["attach_id"] = $var["attach_id"];
     }
     $return["userInfo"] = $user;
     $return["title"] = trim((string) $result[0]->title);
     $return["body"] = trim((string) $result[0]->body);
     $return["info"] = trim((string) $result[0]["info"]);
     $return["body"] = StringUtil::parseHtml($return["body"]);
     $return["api_source"] = $var["sourceInfo"];
     $return["actions"] = $actions["@attributes"];
     if (!$this->notDel($_data["module"], $_data["type"], $_data["rowid"])) {
         $return["body"] = Ibos::lang("Info already delete", "message.default");
     }
     return $return;
 }
开发者ID:AxelPanda,项目名称:ibos,代码行数:56,代码来源:Feed.php


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