本文整理汇总了PHP中tpl_getConf函数的典型用法代码示例。如果您正苦于以下问题:PHP tpl_getConf函数的具体用法?PHP tpl_getConf怎么用?PHP tpl_getConf使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了tpl_getConf函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: tpl_translation
function tpl_translation($conf)
{
if (file_exists(dirname(__FILE__) . '/lang/' . $conf . '/settings.php')) {
return $conf;
}
return tpl_getConf('btl_language');
}
示例2: tpl_sidebar_content
function tpl_sidebar_content()
{
global $ID, $REV, $ACT, $conf;
// save globals
$saveID = $ID;
$saveREV = $REV;
$saveACT = $ACT;
// discover file to be displayed in navigation sidebar
$fileSidebar = '';
if (tpl_getConf('page')) {
$fileSidebar = getSidebarFN(getNS($ID), tpl_getConf('page'));
}
// determine what to display
if ($fileSidebar) {
$ID = $fileSidebar;
$REV = '';
$ACT = 'show';
# print p_wiki_xhtml($fileSidebar,'',false);
tpl_content();
} else {
# global $IDX;
# html_index($IDX);
# $ID = getNS($ID);
$REV = '';
$ACT = 'index';
tpl_content();
}
// restore globals
$ID = $saveID;
$REV = $saveREV;
$ACT = $saveACT;
}
示例3: _tpl_action
/**
* Wrapper around custom template actions
*
* @author Anika Henke <anika@selfthinker.org>
*/
function _tpl_action($type, $link = 0, $wrapper = 0)
{
switch ($type) {
case 'userpage':
if (tpl_getConf('userPage')) {
_tpl_userpage(tpl_getConf('userPage'), tpl_getLang('userpage'), $link, $wrapper);
}
break;
}
}
示例4: tpl_navigation
/**
* Prints the navigation
*
* @author Michael Klier <chi@chimeric.de>
*/
function tpl_navigation()
{
global $ID;
global $conf;
$navpage = tpl_getConf('navigation_page');
print '<div class="navigation">' . DOKU_LF;
if (!page_exists($navpage)) {
if (@file_exists(DOKU_TPLINC . 'lang/' . $conf['lang'] . '/nonavigation.txt')) {
$out = p_render('xhtml', p_get_instructions(io_readFile(DOKU_TPLINC . 'lang/' . $conf['lang'] . '/nonavigation.txt')), $info);
} else {
$out = p_render('xhtml', p_get_instructions(io_readFile(DOKU_TPLINC . 'lang/en/nonavigation.txt')), $info);
}
$link = '<a href="' . wl($navpage) . '" class="wikilink2">' . $navpage . '</a>' . DOKU_LF;
print str_replace('LINK', $link, $out);
} else {
print p_wiki_xhtml($navpage);
}
print '</div>';
}
示例5: tpl_sidebar
function tpl_sidebar()
{
global $ID, $REV, $conf;
// save globals
$saveID = $ID;
$saveREV = $REV;
// discover file to be displayed in navigation sidebar
$fileSidebar = '';
$sidebar_name = tpl_getConf('btl_sidebar_name');
if (isset($sidebar_name)) {
$fileSidebar = getSidebarFN(getNS($ID), $sidebar_name);
}
// determine what to display
if ($fileSidebar) {
$ID = $fileSidebar;
$REV = '';
$sidebar = p_wiki_xhtml($ID, $REV, false);
$lines = explode("\n", $sidebar);
$open_ul = 0;
for ($i = 0; $i < count($lines); $i++) {
if (trim($lines[$i]) == '<ul>') {
$open_ul = $open_ul + 1;
if ($open_ul == 1) {
$lines[$i] = '<ul class="primary">' . "\n";
}
} else {
if (strpos($lines[$i], '</ul>') != false) {
$open_ul = $open_ul - 1;
}
}
}
print implode($lines);
} else {
global $IDX;
html_index($IDX);
}
// restore globals
$ID = $saveID;
$REV = $saveREV;
}
示例6: tpl_sidebar_content
function tpl_sidebar_content()
{
global $ID, $REV, $conf;
// save globals
$saveID = $ID;
$saveREV = $REV;
// discover file to be displayed in navigation sidebar
$fileSidebar = '';
if (tpl_getConf('page')) {
$fileSidebar = getSidebarFN(getNS($ID), tpl_getConf('page'));
}
// determine what to display
if ($fileSidebar) {
$ID = $fileSidebar;
$REV = '';
print p_wiki_xhtml($ID, $REV, false);
} else {
global $IDX;
html_index($IDX);
}
// restore globals
$ID = $saveID;
$REV = $saveREV;
}
示例7:
<?php
if (strpos(tpl_getConf('elements'), 'header_landing_area') !== false) {
include 'tpl_site_header_landing.php';
}
?>
<!-- ********** HEADER ********** -->
<header id="dokuwiki__top">
<?php
include 'tpl_site_header_topbar.php';
?>
<?php
include 'tpl_site_header_nav.php';
?>
</header><!-- /#dokuwiki__header -->
<div id="mixture__content" class="pad">
<?php
html_msgarea();
?>
<!--<div class="clearer"></div>-->
<nav class="tools">
<!-- USER TOOLS -->
<?php
if ($conf['useacl'] && $showTools) {
?>
示例8: tpl_getConf
//RSS recent changes button
$_vector_btns["rss"]["img"] = DOKU_TPL . "static/img/button-rss.png";
$_vector_btns["rss"]["href"] = DOKU_BASE . "feed.php";
$_vector_btns["rss"]["width"] = 80;
$_vector_btns["rss"]["height"] = 15;
$_vector_btns["rss"]["title"] = $lang["vector_recentchanges"];
$_vector_btns["rss"]["nofollow"] = true;
//donation button
if (tpl_getConf("vector_donate")) {
$_vector_btns["donate"]["img"] = DOKU_TPL . "static/img/button-donate.gif";
$_vector_btns["donate"]["href"] = DOKU_BASE . "feed.php";
if (tpl_getConf("vector_donate_default")) {
$_vector_btns["donate"]["href"] = "http://andreas-haerter.com/donate/vector/paypal";
//default url
} else {
$_vector_btns["donate"]["href"] = tpl_getConf("vector_donate_url");
//custom url
}
$_vector_btns["donate"]["width"] = 80;
$_vector_btns["donate"]["height"] = 15;
$_vector_btns["donate"]["title"] = $lang["vector_donate"];
$_vector_btns["donate"]["nofollow"] = true;
}
//"vector for DokuWiki" button
//Note: You are NOT allowed to remove this button. Please respect this!
$_vector_btns["vecfdw"]["img"] = DOKU_TPL . "static/img/button-vector.png";
$_vector_btns["vecfdw"]["href"] = "http://andreas-haerter.com/projects/dokuwiki-template-vector";
$_vector_btns["vecfdw"]["width"] = 80;
$_vector_btns["vecfdw"]["height"] = 15;
$_vector_btns["vecfdw"]["title"] = $lang["vector_mdtemplatefordw"];
$_vector_btns["vecfdw"]["nofollow"] = false;
示例9: tpl_action
tpl_action('recent', 1, 'li');
tpl_action('media', 1, 'li');
tpl_action('index', 1, 'li');
?>
</ul>
</div>
</div>
<!-- TOPBAR - @20cones-template@ -->
<div class="topbar">
<?php
if (tpl_getConf("20cones_htmltopbar")) {
tpl_includeFile('topbar.html');
} else {
tpl_include_page(tpl_getConf("20cones_pagetopbar"), 1, 1);
}
?>
</div>
<!-- BREADCRUMBS -->
<?php
if ($conf['breadcrumbs'] || $conf['youarehere']) {
?>
<div class="breadcrumbs">
<?php
if ($conf['youarehere']) {
?>
<div class="youarehere"><?php
tpl_youarehere();
?>
示例10: p_index_xhtml
/**
* Renders the Index
*
*/
function p_index_xhtml($ns)
{
require_once DOKU_INC . 'inc/search.php';
global $conf;
global $ID;
$dir = $conf['datadir'];
$tpl = $conf['template'];
$start = isset($conf['start']) ? $conf['start'] : 'start';
$ns = getNS($ns);
$data = array();
search($data, $conf['datadir'], 'search_index', array('ns' => $ns));
$i = 0;
$cleanindexlist = array();
if (tpl_getConf('cleanindexlist')) {
$cleanindexlist = explode(',', tpl_getConf('cleanindexlist'));
$i = 0;
foreach ($cleanindexlist as $tmpitem) {
$cleanindexlist[$i] = trim($tmpitem);
$i++;
}
}
$i = 0;
foreach ($data as $item) {
if (tpl_getConf('cleanindex')) {
if (count($cleanindexlist)) {
if (strpos($item['id'], ':')) {
list($tmpitem) = explode(':', $item['id']);
} else {
$tmpitem = $item['id'];
}
if (in_array($tmpitem, $cleanindexlist)) {
unset($data[$i]);
}
}
}
if ($item['id'] == 'sidebar' or $item['id'] == $start or preg_match('/:' . $start . '$/', $item['id']) or !empty($conf['hidepages']) and preg_match('/' . $conf['hidepages'] . '$/', $item['id']) or $item['id'] == $conf['tpl']['dokukit']['extlinks']) {
unset($data[$i]);
}
$i++;
}
# echo index with empty items removed
echo html_buildlist($data, 'idx', '_html_list_index', 'html_li_index');
}
示例11: switch
{
switch ($type) {
case 'register':
// deprecated
_tpl_register($link, $wrapper);
break;
}
}
/* fallbacks for things missing in older DokuWiki versions
********************************************************************/
/* if newer settings exist in the core, use them, otherwise fall back to template settings */
if (!isset($conf['tagline'])) {
$conf['tagline'] = tpl_getConf('tagline');
}
if (!isset($conf['sidebar'])) {
$conf['sidebar'] = tpl_getConf('sidebarID');
}
/* these $lang strings are now in the core */
if (!isset($lang['user_tools'])) {
$lang['user_tools'] = tpl_getLang('user_tools');
}
if (!isset($lang['site_tools'])) {
$lang['site_tools'] = tpl_getLang('site_tools');
}
if (!isset($lang['page_tools'])) {
$lang['page_tools'] = tpl_getLang('page_tools');
}
if (!isset($lang['skip_to_content'])) {
$lang['skip_to_content'] = tpl_getLang('skip_to_content');
}
/**
示例12: _mixture_glyph
echo _mixture_glyph("close", "close");
?>
</label>
<ul>
<?php
_mixture_adminDropdown();
?>
</ul>
</div>
</div>
</div>
</li>
<?php
}
?>
<li>
<?php
_mixture_searchform(true, tpl_getConf('autoComplete'));
?>
</li>
</ul>
</div><!-- #mixture__tools -->
<?php
if ($conf['breadcrumbs'] or $conf['youarehere']) {
include 'tpl_site_header_nav_breadcrumbs.php';
}
?>
</nav>
示例13: switch
<?php
switch (tpl_getConf('wiki_actionlinks')) {
case 'buttons':
tpl_button('edit');
tpl_button('history');
break;
case 'links':
tpl_actionlink('edit');
tpl_actionlink('history');
break;
}
?>
</div>
<div class="bar-right">
<?php
switch (tpl_getConf('wiki_actionlinks')) {
case 'buttons':
tpl_button('backlink');
tpl_button('subscription');
tpl_button('top');
break;
case 'links':
tpl_actionlink('backlink');
tpl_actionlink('subscription');
tpl_actionlink('top');
break;
}
?>
</div>
</div>
<div class="clearer"></div>
示例14: _mixture_stickme
/**
* STICKY OR NOT
*/
function _mixture_stickme($element)
{
if ($element != null and strpos(tpl_getConf('stickies'), $element) !== false) {
return " stickme";
}
}
示例15: hsc
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>
<?php
echo hsc($lang['mediaselect']);
?>
[<?php
echo strip_tags($conf['title']);
?>
]
</title>
<?php
tpl_metaheaders();
?>
<link rel="shortcut icon" href="<?php
echo tpl_getConf('lab_favicon');
?>
" type="image/x-icon" />
</head>
<body>
<div id="media__manager" class="dokuwiki">
<div id="media__left">
<?php
html_msgarea();
?>
<h1><?php
echo hsc($lang['mediaselect']);
?>
</h1>