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


PHP base::baseUrl方法代码示例

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


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

示例1: redirectUrl

 public function redirectUrl($controller, $action = "base")
 {
     $baseurl = base::baseUrl();
     $url = $baseurl . "/{$controller}/{$action}";
     header("location: {$url}");
     die;
 }
开发者ID:mustafakarali,项目名称:orchidframework,代码行数:7,代码来源:controller.php

示例2: addAjaxComponent

 public function addAjaxComponent($container, $controller, $action = "base", $extra = "{}")
 {
     $basepath = base::baseUrl();
     $url = $basepath . "/{$controller}/{$action}";
     $data = "<script>\n\t\t\$(document).ready(function(){\n\t\t\t\$('#{$container}').load('{$url}',{$extra});\n\t\t});\n\t\t</script>";
     return $data;
 }
开发者ID:mustafakarali,项目名称:orchidframework,代码行数:7,代码来源:view.php

示例3: addBluePrint

 public function addBluePrint($iehack = false)
 {
     $basepath = base::baseUrl();
     echo "<style type=\"text/css\"> @import \"{$basepath}/core/styles/bp.css\"; </style>";
     if ($iehack) {
         echo "<!--[if IE]><link rel=\"stylesheet\" href=\"{$basepath}/core/styles/ie.css\" type=\"text/css\" media=\"screen, projection\"><![endif]-->";
     }
 }
开发者ID:mustafakarali,项目名称:orchidframework,代码行数:8,代码来源:cssm.php

示例4: dashboard

 function dashboard()
 {
     $baseurl = base::baseUrl();
     $this->use_view = false;
     $username = $this->session->username;
     if (!empty($username)) {
         echo "<h1 style='margin-bottom:25px;'>Welcome to your blog</h1>";
         echo "You can now create your blog post or <a href='{$baseurl}/blog/logout'>Logout</a>";
     }
 }
开发者ID:mustafakarali,项目名称:orchidframework,代码行数:10,代码来源:blog.php

示例5: _loadTemplate

 public static function _loadTemplate($controller, $template, $vars, $uselayout = false)
 {
     global $debug, $debugparts;
     if ($debug) {
         $_vars = $vars;
         unset($_vars["app"]);
         unset($_vars["lang"]);
         $debugparts[] = array("type" => "view", "value" => array("viewfile" => $template, "controller" => $controller, "params" => $_vars, "layout" => $uselayout));
     }
     extract($vars);
     $baseurl = base::baseUrl();
     if ($uselayout) {
         ob_start();
     }
     $templatefile = "app/views/{$controller}/{$template}.php";
     if (file_exists($templatefile)) {
         include_once $templatefile;
     } else {
         throw new Exception("View '{$template}.php' is not found in views/{$controller} directory.");
     }
     if ($uselayout) {
         //die("using layout)");
         $layoutdata = ob_get_clean();
         $layoutfilelocal = "app/views/{$controller}/{$controller}.php";
         $layoutfileglobal = "app/views/layouts/{$controller}.php";
         if (file_exists($layoutfilelocal)) {
             include_once $layoutfilelocal;
         } else {
             if (file_exists($layoutfileglobal)) {
                 include_once $layoutfileglobal;
             } else {
                 echo $layoutdata;
             }
         }
     }
 }
开发者ID:mustafakarali,项目名称:orchidframework,代码行数:36,代码来源:base.php

示例6: addYahooUIFromGoogle

 function addYahooUIFromGoogle()
 {
     $base = base::baseUrl();
     echo "<script type='text/javascript' src='http://ajax.googleapis.com/ajax/libs/yui/2.7.0/build/yuiloader/yuiloader-min.js' ></script>\n";
 }
开发者ID:mustafakarali,项目名称:orchidframework,代码行数:5,代码来源:jsm.php

示例7: getUrl

 function getUrl($filename = "")
 {
     $imagepath = base::baseUrl() . "/app/images/{$filename}";
     return $imagepath;
 }
开发者ID:mustafakarali,项目名称:orchidframework,代码行数:5,代码来源:image.php

示例8: getCurrentURL

function getCurrentURL()
{
    $router = loader::load("router");
    $url = base::baseUrl() . "/" . $router->getRoute();
    return $url;
}
开发者ID:mustafakarali,项目名称:orchidframework,代码行数:6,代码来源:general.php

示例9: url

 private static final function url($url)
 {
     self::$baseUrl = $url;
     return self::$baseUrl;
 }
开发者ID:suconghou,项目名称:sprite,代码行数:5,代码来源:base.php

示例10: header

<?php

header("Content-type: text/javascript; charset: UTF-8");
?>
var baseUrl = "<?php 
echo base::baseUrl();
?>
";

function addFLVPlayer(playerurl,url, width, height, container,preview, allowfullscreen)
{
	var s1 = new SWFObject(playerurl,"single",width,height,"7");
	s1.addParam("allowfullscreen",allowfullscreen);
	s1.addVariable("file",url);
	if (preview!="")
	s1.addVariable("image",preview);
	s1.addVariable("width",width);
	s1.addVariable("height",height);
	s1.write(container);

function isIE()
{
	if (document.all) return true;
	return false;
}

function submitForm(formId)
{
	formId = "#"+formId;

	//if (!action)
开发者ID:mustafakarali,项目名称:orchidframework,代码行数:31,代码来源:general.php


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