本文整理汇总了PHP中site_title函数的典型用法代码示例。如果您正苦于以下问题:PHP site_title函数的具体用法?PHP site_title怎么用?PHP site_title使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了site_title函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: detail
public function detail($id = null)
{
if ($id === null) {
redirect('/gallery', 'refresh');
}
$this->load->model('gallery_model', 'gallery');
$data['gallery'] = $this->gallery->getSingleGallery($id);
$data['images'] = $this->gallery->getGalleryImages($id);
$data['title'] = site_title($data['gallery']->gallery_title);
$this->load->view('gallery/gallery-detail', $data);
}
示例2: main
/**
* 默认首页
*/
public function main()
{
if (u()->getUriInfo()->getUrlListLast() !== null) {
$this->__load_404();
} else {
header("Content-Type: text/html; charset=utf-8");
theme()->set_desc(site_title(false) . " - " . site_desc(false));
theme()->set_keywords(site_keywords());
$this->__view('comm/header.php');
$this->__view('home/home.php');
$this->__view('comm/footer.php');
}
}
示例3: detail
function detail($id = null)
{
if ($id === null) {
$this->uri->redirect(site_url() . 'store', 'refresh');
//redirect them back to the store page.
}
$this->load->model('store_model');
$data['pageTitle'] = $this->store_model->getProductTitle($id);
$data['title'] = site_title($data['pageTitle']);
$data['defaultImage'] = $this->store_model->getProductImage($id);
//default iamge.
$data['productImages'] = $this->store_model->getProductImages($id);
$data['product'] = $this->store_model->getProduct($id);
$this->load->view('store/product-detail', $data);
}
示例4: display
function display()
{
current_page('page');
if (!user('logged')) {
return login_req();
}
$data = ldb_select_one('page', '*', input(1), 'name');
if (!$data) {
return core_error_404();
}
page_title($data['title']);
site_title($data['title']);
$out = '';
$out .= $data['text'];
return $out;
}
示例5: page
/**
* 单独页面
* @param $page
*/
public function page($page)
{
if (\ULib\Router::$begin_status) {
lib()->load('project', 'menu')->add("project", new \ULib\Project($page, 0));
lib()->add('menu', new \ULib\Menu(true));
set_title(project()->title(), site_title(false));
theme()->header_add("<script>var PM_PAGE_ID = " . project()->id() . ";</script>", 40);
theme()->set_desc(project()->desc());
theme()->set_keywords(project()->keywords());
header("Content-Type:text/html; charset=utf-8");
$this->__view('comm/header.php');
$this->__view('project/page.php');
$this->__view('comm/footer.php');
} else {
$this->__load_404();
}
}
示例6: create
public function create()
{
$this->add_header();
$this->add(get_url(), gmdate(DATE_ATOM, time()), 'daily', '1.0', site_title(false) . " | " . site_desc(false));
$page = db()->select("project", array('[><]page' => array('page_id' => 'id')), array('project.id' => 'id', 'project.name' => 'name', 'project.title' => 'title', 'project.desc' => 'desc', 'page.uptime' => 'time'), array('project.type' => 'page', 'ORDER' => 'sort'));
foreach ($page as $v) {
$this->add(get_url($v['name']), $this->date_convert($v['time']), 'weekly', '0.8', $v['title'] . " - " . site_title(false));
}
unset($page);
$project = db()->select("project", array('[><]page' => array('page_id' => 'id')), array('project.id' => 'id', 'project.name' => 'name', 'project.title' => 'title', 'project.desc' => 'desc', 'page.uptime' => 'time'), array('project.type' => 'project', 'ORDER' => 'sort'));
foreach ($project as $v) {
$this->add(get_url($v['name']), $this->date_convert($v['time']), 'weekly', '0.7', $v['title'] . " - " . site_title(false));
foreach (db()->select("item", array('[><]page' => array('page_id' => 'id')), array('item.name' => 'name', 'item.title' => 'title', 'item.desc' => 'desc', 'page.uptime' => 'time'), array('item.project_id' => $v['id'])) as $v2) {
$this->add(get_url($v['name'], $v2['name']), $this->date_convert($v2['time']), 'monthly', '0.5', $v2['title'] . " - " . $v['title']);
}
}
$this->add_footer();
}
示例7: option_resources
function option_resources($preset = '')
{
$qry = "SELECT * FROM sites WHERE ep_occi != '' ORDER BY cmf";
$ret = myQuery($qry);
$opts = "<option>::select a site::</option>";
while ($row = myFetchRow($ret)) {
//dd($row);
$v = $row['id'];
$t = site_title($row);
if ($preset == $v) {
$sel = " selected";
} else {
$sel = '';
}
$opts .= "<option value='{$v}'{$sel}>{$t}</option>";
}
return $opts;
}
示例8: pm_title
/**
* 输出标题
* @param bool $out
* @return mixed
*/
function pm_title($out = true)
{
$title = hook()->apply('pm_title_title', cfg()->get('theme', 'title'));
$desc = hook()->apply('pm_title_title', cfg()->get('theme', 'desc'));
if ($title === null) {
$title = site_title(false);
}
if ($desc === null) {
$desc = site_desc(false);
}
if (empty($desc)) {
$out = hook()->apply('pm_title', $title);
} else {
$out = hook()->apply('pm_title', $title . " | " . site_name(false));
}
if ($out) {
echo $out;
}
return $out;
}
示例9: set_title_and_breadcrumbs
protected function set_title_and_breadcrumbs($title = array(), $middle_breadcrumbs = array(), $member_obj = null, $module = null, $info = array(), $is_no_breadcrumbs = false, $is_no_title = false, $ogp_data = array())
{
$common = array('title' => FBD_SITE_NAME, 'description' => FBD_SITE_DESCRIPTION);
$title_name = '';
$this->template->title = '';
if ($title) {
list($title_name, $title_label) = Site_Controller::get_title_parts($title);
}
if (!$is_no_title && $title_name) {
$this->template->title = View::forge('_parts/page_title', array('name' => $title_name, 'label' => $title_label));
$common['title'] = $title_name;
}
$this->template->header_title = site_title($title_name);
if ($info) {
$this->template->header_info = View::forge('_parts/information', $info);
}
$this->template->breadcrumbs = $is_no_breadcrumbs ? array() : static::get_breadcrumbs($title_name, $middle_breadcrumbs, $member_obj, $member_obj ? $this->check_is_mypage($member_obj->id) : false, $module);
if (!empty($ogp_data['title'])) {
$common['title'] = $ogp_data['title'];
}
if (!empty($ogp_data['description'])) {
$common['description'] = $ogp_data['description'];
}
if (!empty($ogp_data['image'])) {
$common['image'] = $ogp_data['image'];
}
View::set_global('common', $common);
}
示例10: OpenGraph
<meta name="keywords" content="<?php
echo $site_keywords;
?>
" />
<meta name="google-site-verification" content="<?php
echo $settings['services']['google_webmaster'];
?>
" />
<meta name="msvalidate.01" content="<?php
echo $settings['services']['bing_webmaster'];
?>
" />
<!-- OpenGraph (Facebook) http://ogp.me -->
<meta property="og:title" content="<?php
echo site_title($sub_title, $page_title, $site_title);
?>
"/>
<meta property="og:type" content="website" />
<meta property="og:image" content="<?php
echo $site_image;
?>
"/>
<meta property="og:url" content="<?php
echo current_url();
?>
"/>
<meta property="og:site_name" content="<?php
echo config_item('site_title');
?>
"/>
示例11: register_hook
public function register_hook()
{
$hook = hook();
$hook->add('UserRegister_Register_before', function ($code) {
if ($code === 0 && !allowed_register()) {
return -11;
}
return $code;
});
switch (site_mode()) {
case "https":
if (!is_ssl()) {
header("Cache-Control: no-cache, must-revalidate");
header("Pragma: no-cache");
redirect("https://" . substr(URL_NOW, 6), "header", 301);
}
$hook->add('get_url', function () {
return site_url_ssl();
});
$hook->add("get_file_url", function () {
return site_static_url_ssl();
});
break;
case "all":
if (is_ssl()) {
$hook->add('get_url', function () {
return site_url_ssl();
});
$hook->add("get_file_url", function () {
return site_static_url_ssl();
});
} else {
$hook->add('get_url', function () {
return site_url();
});
$hook->add("get_file_url", function () {
return site_static_url();
});
}
break;
default:
if (is_ssl()) {
header("Cache-Control: no-cache, must-revalidate");
header("Pragma: no-cache");
redirect("http://" . substr(URL_NOW, 7), "header", 301);
}
$hook->add('get_url', function () {
return site_url();
});
$hook->add("get_file_url", function () {
return site_static_url();
});
}
$hook->add("UserRegister_CodeMsg", function ($msg, $code) {
if ($code == -11) {
return _("User register already closed.");
}
return $msg;
});
if (!login_captcha()) {
//将验证码检测返回TRUE
$hook->add("UserLogin_Captcha", function () {
return true;
});
}
if (email_notice()) {
$hook->add('UserRegister_Register_success', function ($user_id) {
lib()->load('MailTemplate');
$user = User::getUser($user_id);
$mt = new MailTemplate("new_user_registered.html");
$mt->setUserInfo($user->getInfo());
$mt->mailSend(site_title() . " Manager", admin_email());
});
}
if (strtolower(default_avatar_config()) == "gravatar") {
$hook->add("Avatar_convert", function ($avatar) {
if (strtolower($avatar) == "{default}") {
return "{gravatar}";
}
return $avatar;
});
}
}
示例12: site_title
<meta name="application-name" content="<?php
site_title();
?>
">
<link rel="icon" sizes="192x192" href="images/touch/chrome-touch-icon-192x192.png">
<!-- Add to homescreen for Safari on iOS --><meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta name="apple-mobile-web-app-title" content="Web Starter Kit">
<link rel="apple-touch-icon" href="images/touch/apple-touch-icon.png">
<!-- Tile icon for Win8 (144x144 + tile color) --><meta name="msapplication-TileImage" content="images/touch/ms-touch-icon-144x144-precomposed.png">
<meta name="msapplication-TileColor" content="#3372DF">
<meta name="theme-color" content="#3372DF">
<!-- Page styles -->
<link rel="stylesheet" href="./system/appearance/system.css">
<link rel="stylesheet" href="extras/themes/acupuncture/styles/main.css">
<link href='http://fonts.googleapis.com/css?family=PT+Sans:400,700,400italic,700italic|Signika:400,600' rel='stylesheet' type='text/css'>
</head>
<body id="nav_top">
<header class="app-bar promote-layer"><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<div class="app-bar-container">
<button class="menu"><img src="<?php
theme_location();
?>
images/hamburger.png" alt="Menu"></button><section class="app-bar-actions"><!-- Put App Bar Buttons Here --><!-- e.g <button><i class="icon icon-star"></i></button> --></section>
<h2 class="sc-content-title main-title"><?php
site_title();
?>
</h2>
</div>
</header><!-- HTML --><!-- HTML -->
示例13: site_title
<?php
require 'inc/functions.php';
?>
<!doctype html>
<html>
<head>
<meta charset="utf-8"/>
<meta content="tekst" name="description" />
<meta content="fjale kyce" name="keywords" />
<title><?php
site_title(' → ');
?>
</title>
<link type="text/css" href="<?php
echo BASEURL;
?>
/style.css" rel="stylesheet" media="screen" />
</head>
<body>
<div id="trupi" class="eperbashket">
<div id="logo">
<img src="<?php
echo BASEURL;
示例14: getSystemParams
/**
* 获取网站系统参数
* @return array
*/
private function getSystemParams()
{
return ['site_url' => site_url(), 'site_title' => site_title(), 'site_desc' => site_desc(), 'admin_email' => admin_email(), 'site_time' => date("Y-m-d H:i:s")];
}
示例15: date_default_timezone_set
<?php
// Change this to your timezone
date_default_timezone_set('America/Los_Angeles');
// Index
// --------------------------------------------------------------------------------
get('/index', function () {
render('index', array('head_title' => site_title()));
});
// Login/Register
// --------------------------------------------------------------------------------
get('/login', function () {
render('login', array('head_title' => 'Login'));
});
post('/login', function () {
$email = from($_REQUEST, 'email');
$password = from($_REQUEST, 'password');
if (account_auth($email, $password)) {
create_session($email);
redirect();
} else {
redirect('/login?error=Incorrect email or password');
}
});
get('/register', function () {
render('register', array('head_title' => 'Register'));
});
post('/register', function () {
$username = from($_REQUEST, 'username');
$email = from($_REQUEST, 'email');
$password = from($_REQUEST, 'password');