本文整理汇总了PHP中add_headline函数的典型用法代码示例。如果您正苦于以下问题:PHP add_headline函数的具体用法?PHP add_headline怎么用?PHP add_headline使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了add_headline函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: display_init
/**
* Get ready for displaying the skin.
*
* This may register some CSS or JS...
*/
function display_init()
{
// call parent:
parent::display_init();
// Add CSS:
require_css('basic_styles.css', 'blog');
// the REAL basic styles
require_css('basic.css', 'blog');
// Basic styles
require_css('blog_base.css', 'blog');
// Default styles for the blog navigation
require_css('item_base.css', 'blog');
// Default styles for the post CONTENT
require_js('ajax.js', 'blog');
require_js('functions.js');
require_js('rollovers.js');
// Make sure standard CSS is called ahead of custom CSS generated below:
require_css('style.css', 'relative');
// Width switch styles
add_headline('<link rel="stylesheet" href="style.css" type="text/css" title="fixed"/>');
add_headline('<link rel="alternate stylesheet" href="fluid.css" type="text/css" title="fluid"/>');
add_headline('<script type="text/javascript" src="rsc/js/styleswitcher.js"></script>');
// Colorbox (a lightweight Lightbox alternative) allows to zoom on images and do slideshows with groups of images:
if ($this->get_setting("colorbox")) {
require_js_helper('colorbox', 'blog');
}
}
示例2: display_init
/**
* Get ready for displaying the skin.
*/
function display_init()
{
require_js('#jquery#');
add_headline('<!--[if lte IE 6]> <script type="text/javascript"> isIE6 = true; isIE = true; </script> <![endif]-->
<!--[if gte IE 7]> <script type="text/javascript"> isIE = true; </script> <![endif]-->');
require_js('resources/jquery.mystique.js', true);
if ($this->get_setting('fancy_helper')) {
require_js('resources/jquery.custom.fancy.js', true);
add_headline('<!-- Add Thumbnail helper (this is optional) -->');
require_css('resources/helpers/jquery.fancybox-thumbs.css', true);
require_js('resources/helpers/jquery.fancybox-thumbs.js', true);
require_css('resources/helpers/jquery.fancybox-buttons.css', true);
require_js('resources/helpers/jquery.fancybox-buttons.js', true);
}
/*
<script language="javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js" type="text/javascript"></script>
<script language="javascript" src="/tweet/jquery.tweet.js" type="text/javascript"></script>
*/
if ($this->get_setting('enable_thumbshots')) {
// Display thumbshots
add_js_headline('jQuery(document).ready(function() {
if( ThumbsLinks = jQuery(".bText a[href^=\'http:\']").not("[href*=\'" + window.location.host + "\']") )
{
ThumbshotPopups("thumbshot", ThumbsLinks);
}
})');
}
add_css_headline(' #page {font-family: ' . $this->get_setting('skin_font') . '}');
require_css('resources/color-' . $this->get_setting('skin_color') . '.css', true);
// call parent:
parent::display_init();
}
示例3: display_init
/**
* Get ready for displaying the skin.
*
* This may register some CSS or JS...
*/
function display_init()
{
// Request some common features that the parent function (Skin::display_init()) knows how to provide:
parent::display_init(array('b2evo_base_css', 'colorbox', 'disp_auto'));
// $this->require_css( 'style.css' );
// $this->require_css( 'item.css' );
// $this->require_css( 'evopress.bundle.css' ); // Concatenation of the above
$this->require_css('evopress.bmin.css');
// Concatenation + Minifaction of the above
// Add custom CSS:
$custom_css = '';
$head_bg_color_top = $this->get_setting('head_bg_color_top');
$head_bg_color_bottom = $this->get_setting('head_bg_color_bottom');
if (!empty($head_bg_color_top) && !empty($head_bg_color_bottom)) {
// Custom Header background color:
$custom_css .= '#headerimg {' . "\n" . 'background: linear-gradient( to bottom, ' . $head_bg_color_top . ', ' . $head_bg_color_bottom . ');' . "\n" . '}' . "\n";
}
if (!empty($custom_css)) {
$custom_css = '<style type="text/css">
<!--
' . $custom_css . ' -->
</style>';
add_headline($custom_css);
}
}
示例4: display_init
/**
* Get ready for displaying the skin.
*
* This may register some CSS or JS...
*/
function display_init()
{
// call parent:
parent::display_init();
// Add CSS:
require_css('basic_styles.css', 'blog');
// the REAL basic styles
require_css('basic.css', 'blog');
// Basic styles
require_css('blog_base.css', 'blog');
// Default styles for the blog navigation
require_css('item_base.css', 'blog');
// Default styles for the post CONTENT
require_css('rsc/css/item.css', 'relative');
require_css('rsc/css/style.css', 'relative');
// Add custom CSS:
$custom_css = '';
$html5support = '';
if ($this->get_setting('html5_support') == '1') {
// HTML5 Support
$html5support .= '
<!--[if IE]>
<script src="rsc/js/html5.js"></script>
<![endif]-->
<link rel="stylesheet" href="rsc/css/html5.css" type="text/css" />
';
}
$custom_css = '' . $html5support . "\n";
add_headline($custom_css);
// Colorbox (a lightweight Lightbox alternative) allows to zoom on images and do slideshows with groups of images:
if ($this->get_setting("colorbox")) {
require_js_helper('colorbox', 'blog');
}
}
示例5: init_templates
/**
* This function should init the templates - like adding Javascript through the {@link add_headline()} method.
*/
function init_templates()
{
global $Hit;
// This is included before controller specifc require_css() calls:
require_css('basic_styles.css', 'rsc_url');
// the REAL basic styles
require_css('basic.css', 'rsc_url');
// Basic styles
require_css('results.css', 'rsc_url');
// Results/tables styles
require_css('item_base.css', 'rsc_url');
// Default styles for the post CONTENT
require_css('fileman.css', 'rsc_url');
// Filemanager styles
require_css('admin.global.css', 'rsc_url');
// Basic admin styles
require_css('skins_adm/chicago/rsc/css/chicago.css', true);
if ($Hit->is_IE()) {
require_css('admin_global_ie.css', 'rsc_url');
}
// CSS for IE9
add_headline('<!--[if IE 9 ]>');
require_css('ie9.css', 'rsc_url');
add_headline('<![endif]-->');
require_js('#jquery#', 'rsc_url');
require_js('jquery/jquery.raty.min.js', 'rsc_url');
}
示例6: display_init
/**
* Get ready for displaying the skin.
*
* This may register some CSS or JS...
*/
function display_init()
{
// call parent:
parent::display_init();
// Add CSS:
require_css('basic_styles.css', 'blog');
// the REAL basic styles
require_css('basic.css', 'blog');
// Basic styles
require_css('blog_base.css', 'blog');
// Default styles for the blog navigation
require_css('item_base.css', 'blog');
// Default styles for the post CONTENT
// Make sure standard CSS is called ahead of custom CSS generated below:
require_css('style.css', true);
// Add custom CSS:
$custom_css = '';
if ($body_bg_color = $this->get_setting('body_bg_color')) {
// Custom Header background color:
$custom_css .= ' body { background-color: ' . $body_bg_color . " }\n";
}
if (!empty($custom_css)) {
$custom_css = '<style type="text/css">
<!--
' . $custom_css . ' -->
</style>';
add_headline($custom_css);
}
// Colorbox (a lightweight Lightbox alternative) allows to zoom on images and do slideshows with groups of images:
if ($this->get_setting("colorbox")) {
require_js_helper('colorbox', 'blog');
}
}
示例7: SkinBeginHtmlHead
/** Plugin Hooks **/
function SkinBeginHtmlHead(&$params)
{
global $Blog;
if ($this->get_coll_setting('sharethis_enabled', $Blog)) {
$url = 'http://w.sharethis.com/button/buttons.js';
require_js($url);
add_headline('<script type="text/javascript">stLight.options({publisher:"' . $this->get_coll_setting('sharethis_publisher_id', $Blog) . '",onhover: false});</script>');
}
}
示例8: display_init
/**
* Get ready for displaying the skin.
*
* This may register some CSS or JS...
*/
function display_init()
{
// call parent:
parent::display_init();
// We pass NO params. This gives up the default Skins API v5 behavior.
// Add custom CSS:
$custom_css = '';
if ($body_bg_color = $this->get_setting('body_bg_color')) {
// Custom Header background color:
$custom_css .= ' body { background-color: ' . $body_bg_color . " }\n";
}
if (!empty($custom_css)) {
$custom_css = '<style type="text/css">
<!--
' . $custom_css . ' -->
</style>';
add_headline($custom_css);
}
}
示例9: display_init
/**
* Get ready for displaying the skin.
*
* This may register some CSS or JS...
*/
function display_init()
{
// call parent:
parent::display_init();
// We pass NO params. This gives up the default Skins API v5 behavior.
// Add custom CSS:
$custom_css = '';
// Custom menu styles:
$custom_styles = array();
if ($bg_color = $this->get_setting('menu_bg_color')) {
// Background color:
$custom_styles[] = 'background-color: ' . $bg_color;
}
if ($text_color = $this->get_setting('menu_text_color')) {
// Text color:
$custom_styles[] = 'color: ' . $text_color;
}
if (!empty($custom_styles)) {
$custom_css .= ' div.pageHeader { ' . implode(';', $custom_styles) . " }\n";
}
// Custom page styles:
$custom_styles = array();
if ($bg_color = $this->get_setting('page_bg_color')) {
// Background color:
$custom_styles[] = 'background-color: ' . $bg_color;
}
if ($text_color = $this->get_setting('page_text_color')) {
// Text color:
$custom_styles[] = 'color: ' . $text_color;
}
if (!empty($custom_styles)) {
$custom_css .= ' body { ' . implode(';', $custom_styles) . " }\n";
}
// Custom post area styles:
$custom_styles = array();
if ($bg_color = $this->get_setting('post_bg_color')) {
// Background color:
$custom_styles[] = 'background-color: ' . $bg_color;
}
if ($text_color = $this->get_setting('post_text_color')) {
// Text color:
$custom_styles[] = 'color: ' . $text_color;
}
if (!empty($custom_styles)) {
$custom_css .= ' div.bDetails { ' . implode(';', $custom_styles) . " }\n";
}
global $thumbnail_sizes;
$posts_thumb_size = $this->get_setting('posts_thumb_size');
if (isset($thumbnail_sizes[$posts_thumb_size])) {
// Make the width of image block as fixed to don't expand it by long post title text
$custom_css .= ' .posts_list .bPost { max-width:' . $thumbnail_sizes[$posts_thumb_size][1] . "px }\n";
// Set width & height for block with text "No pictures yet"
$custom_css .= ' .posts_list .bPost b { width:' . ($thumbnail_sizes[$posts_thumb_size][1] - 20) . 'px;' . 'height:' . ($thumbnail_sizes[$posts_thumb_size][2] - 20) . 'px' . " }\n";
}
$single_thumb_size = $this->get_setting('single_thumb_size');
if (isset($thumbnail_sizes[$single_thumb_size])) {
// Make the width of image block as fixed to don't expand it by long post title text
$custom_css .= ' .post_images .image_block .image_legend { width:' . $thumbnail_sizes[$single_thumb_size][1] . 'px; max-width:' . $thumbnail_sizes[$single_thumb_size][1] . "px }\n";
// Set width & height for block with text "No pictures yet"
/*$custom_css .= ' .posts_list .bPost b { width:'.( $thumbnail_sizes[ $single_thumb_size ][1] - 20 ).'px;'
.'height:'.( $thumbnail_sizes[ $single_thumb_size ][2] - 20 ).'px'." }\n";*/
}
if (!empty($custom_css)) {
$custom_css = '<style type="text/css">
<!--
' . $custom_css . ' -->
</style>';
add_headline($custom_css);
}
}
示例10: add_headline
\t\t\t\t\t\t\tif( document.getElementById( idprefix+'_state_'+String(index)) )
\t\t\t\t\t\t\t{
\t\t\t\t\t\t\t\tsetcheckallspan( index, document.getElementById( idprefix+'_state_'+String(index)).checked );
\t\t\t\t\t\t\t}
\t\t\t\t\t\t\telse
\t\t\t\t\t\t\t{
\t\t\t\t\t\t\t\tsetcheckallspan( index, init );
\t\t\t\t\t\t\t}
\t\t\t\t\t\t}
\t\t\t\t\t}
\t\t\t\t}
\t\t\t}
\t\t\t//-->
\t\t</script>
JS;
add_headline($initcheckall_script);
}
// Add event to the item title field to update document title and init it (important when switching tabs/blogs):
global $js_doc_title_prefix;
if (isset($js_doc_title_prefix)) {
// dynamic document.title handling:
$base_title = preg_quote(trim($js_doc_title_prefix));
add_js_headline('jQuery(function(){
var generateTitle = function()
{
currentPostTitle = jQuery(\'#post_title\').val()
document.title = document.title.replace(/(' . $base_title . ').*$/, \'$1 \'+currentPostTitle)
}
generateTitle()
jQuery(\'#post_title\').keyup(generateTitle)
})');
示例11: display_init
/**
* Get ready for displaying the skin.
*
* This may register some CSS or JS...
*/
function display_init()
{
global $Messages, $debug;
// Request some common features that the parent function (Skin::display_init()) knows how to provide:
parent::display_init(array('jquery', 'font_awesome', 'bootstrap', 'bootstrap_evo_css', 'bootstrap_messages', 'style_css', 'colorbox', 'bootstrap_init_tooltips', 'disp_auto'));
// Skin specific initializations:
// Limit images by max height:
$max_image_height = intval($this->get_setting('max_image_height'));
if ($max_image_height > 0) {
add_css_headline('.evo_image_block img { max-height: ' . $max_image_height . 'px; width: auto; }');
}
// Add custom CSS:
$custom_css = '';
// Font size customization
if ($font_size = $this->get_setting('font_size')) {
switch ($font_size) {
case 'default':
// When default font size, no CSS entry
$custom_css = '';
break;
case 'standard':
// When standard layout
$custom_css = '.container p, .container ul li, .container div, .container label, .container textarea, .container input { font-size: 16px !important' . " }\n";
$custom_css .= '.container input.search_field { height: 100%' . " }\n";
$custom_css .= '.container h1 { font-size: 38px' . " }\n";
$custom_css .= '.container h2 { font-size: 32px' . " }\n";
$custom_css .= '.container h3 { font-size: 26px' . " }\n";
$custom_css .= '.container h4 { font-size: 18px' . " }\n";
$custom_css .= '.container h5 { font-size: 16px' . " }\n";
$custom_css .= '.container h6 { font-size: 14px' . " }\n";
$custom_css .= '.container .small { font-size: 85% !important' . " }\n";
break;
case 'medium':
// When default font size, no CSS entry
$custom_css = '.container p, .container ul li, .container div, .container label, .container textarea, .container input { font-size: 18px !important' . " }\n";
$custom_css .= '.container input.search_field { height: 100%' . " }\n";
$custom_css .= '.container h1 { font-size: 40px' . " }\n";
$custom_css .= '.container h2 { font-size: 34px' . " }\n";
$custom_css .= '.container h3 { font-size: 28px' . " }\n";
$custom_css .= '.container h4 { font-size: 20px' . " }\n";
$custom_css .= '.container h5 { font-size: 18px' . " }\n";
$custom_css .= '.container h6 { font-size: 16px' . " }\n";
$custom_css .= '.container .small { font-size: 85% !important' . " }\n";
break;
case 'large':
// When default font size, no CSS entry
$custom_css = '.container p, .container ul li, .container div, .container label, .container textarea, .container input { font-size: 20px !important' . " }\n";
$custom_css .= '.container input.search_field { height: 100%' . " }\n";
$custom_css .= '.container h1 { font-size: 42px' . " }\n";
$custom_css .= '.container h2 { font-size: 36px' . " }\n";
$custom_css .= '.container h3 { font-size: 30px' . " }\n";
$custom_css .= '.container h4 { font-size: 22px' . " }\n";
$custom_css .= '.container h5 { font-size: 20px' . " }\n";
$custom_css .= '.container h6 { font-size: 18px' . " }\n";
$custom_css .= '.container .small { font-size: 85% !important' . " }\n";
break;
case 'very_large':
// When default font size, no CSS entry
$custom_css = '.container p, .container ul li, .container div, .container label, .container textarea, .container input { font-size: 22px !important' . " }\n";
$custom_css .= '.container input.search_field { height: 100%' . " }\n";
$custom_css .= '.container h1 { font-size: 44px' . " }\n";
$custom_css .= '.container h2 { font-size: 38px' . " }\n";
$custom_css .= '.container h3 { font-size: 32px' . " }\n";
$custom_css .= '.container h4 { font-size: 24px' . " }\n";
$custom_css .= '.container h5 { font-size: 22px' . " }\n";
$custom_css .= '.container h6 { font-size: 20px' . " }\n";
$custom_css .= '.container .small { font-size: 85% !important' . " }\n";
break;
}
}
if (!empty($custom_css)) {
// Function for custom_css:
$custom_css = '<style type="text/css">
<!--
' . $custom_css . '
-->
</style>';
add_headline($custom_css);
}
}
示例12: init_plugins_js
/**
* Registers headlines required to display a bubbletip to the right of plugin help icon.
*/
function init_plugins_js($relative_to = 'rsc_url')
{
require_js('#jquery#', $relative_to);
// dependency
require_js('jquery/jquery.bubbletip.min.js', $relative_to);
require_js('plugins.js', $relative_to);
require_css('jquery/bubbletip/bubbletip.css', $relative_to);
add_headline('<!--[if IE]>');
require_css('jquery/bubbletip/bubbletip-IE.css', $relative_to);
add_headline('<![endif]-->');
}
示例13: die
* @version $Id: page.main.php,v 1.8.2.1 2008/04/26 22:28:54 fplanque Exp $
*/
if (!defined('EVO_MAIN_INIT')) {
die('Please, do not access this page directly.');
}
if (version_compare($app_version, '2.4.1') < 0) {
// Older 2.x skins work on newer 2.x b2evo versions, but newer 2.x skins may not work on older 2.x b2evo versions.
die('This skin is designed for b2evolution 2.4.1 and above. Please <a href="http://b2evolution.net/downloads/index.html">upgrade your b2evolution</a>.');
}
// This is the main template; it may be used to display very different things.
// Do inits depending on current $disp:
skin_init($disp);
// -------------------------- HTML HEADER INCLUDED HERE --------------------------
add_headline(<<<HEREDOC
<style type="text/css" media="screen">
\t#page { background: url("img/kubrickbgwide.jpg") repeat-y top; }
</style>
HEREDOC
);
skin_include('_html_header.inc.php');
// Note: You can customize the default HTML header by copying the generic
// /skins/_html_header.inc.php file into the current skin folder.
// -------------------------------- END OF HEADER --------------------------------
?>
<?php
// ------------------------- BODY HEADER INCLUDED HERE --------------------------
skin_include('_body_header.inc.php');
// Note: You can customize the default BODY header by copying the generic
// /skins/_body_footer.inc.php file into the current skin folder.
// ------------------------------- END OF FOOTER --------------------------------
示例14: display_init
/**
* Get ready for displaying the skin.
*
* This may register some CSS or JS...
*/
function display_init()
{
global $disp;
// call parent:
parent::display_init();
// Add CSS:
require_css('basic_styles.css', 'blog');
// the REAL basic styles
require_css('basic.css', 'blog');
// Basic styles
require_css('blog_base.css', 'blog');
// Default styles for the blog navigation
require_css('item_base.css', 'blog');
// Default styles for the post CONTENT
require_css('style.css', 'relative');
// Add custom CSS:
$custom_css = '';
// Colorbox (a lightweight Lightbox alternative) allows to zoom on images and do slideshows with groups of images:
if ($this->get_setting("colorbox")) {
require_js_helper('colorbox', 'blog');
}
if ($main_content_headline = $this->get_setting('main_content_headline')) {
// Custom introduction title:
$custom_css .= 'div#main h1:before { content: "' . $main_content_headline . '" }';
}
if ($main_content = $this->get_setting('main_content')) {
// Custom inroduction text:
$custom_css .= 'div#main p:before { content: "' . $main_content . '" }';
}
if (!empty($custom_css)) {
if ($disp == 'front') {
// Use standard bootstrap style on width <= 640px only for disp=front
$custom_css = '@media only screen and (min-width: 641px)
{
' . $custom_css . '
}';
}
$custom_css = '<style type="text/css">
<!--
' . $custom_css . '
-->
</style>';
add_headline($custom_css);
}
}
示例15: die
*
* @version $Id: index.main.php 4275 2013-07-17 10:52:24Z yura $
*/
if (!defined('EVO_MAIN_INIT')) {
die('Please, do not access this page directly.');
}
if (version_compare($app_version, '3.0') < 0) {
// Older skins (versions 2.x and above) should work on newer b2evo versions, but newer skins may not work on older b2evo versions.
die('This skin is designed for b2evolution 3.0 and above. Please <a href="http://b2evolution.net/downloads/index.html">upgrade your b2evolution</a>.');
}
// This is the main template; it may be used to display very different things.
// Do inits depending on current $disp:
skin_init($disp);
// -------------------------- HTML HEADER INCLUDED HERE --------------------------
// Initializations:
add_headline('<!--[if IE]><link rel="stylesheet" type="text/css" href="ie.css" /><![endif]-->');
// Include the HTML HEAD:
skin_include('_html_header.inc.php');
// Note: You can customize the default HTML header by copying the
// _html_header.inc.php file into the current skin folder.
// -------------------------------- END OF HEADER --------------------------------
?>
<div class="wrapper">
<div class="wrapper2">
<div class="outerwrap">
<div class="innerwrap">
<div class="PageTop">