當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Skin::display_init方法代碼示例

本文整理匯總了PHP中Skin::display_init方法的典型用法代碼示例。如果您正苦於以下問題:PHP Skin::display_init方法的具體用法?PHP Skin::display_init怎麽用?PHP Skin::display_init使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Skin的用法示例。


在下文中一共展示了Skin::display_init方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: display_init

 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:
 }
開發者ID:b2evolution,項目名稱:firming_skin,代碼行數:7,代碼來源:_skin.class.php

示例2:

 /**
  * 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');
     }
 }
開發者ID:b2evolution,項目名稱:grey_skale_skin,代碼行數:32,代碼來源:_skin.class.php

示例3:

 /**
  * Get ready for displaying the skin.
  *
  * This may register some CSS or JS...
  */
 function display_init()
 {
     // call parent:
     parent::display_init();
     // Add CSS:
     // fp> Note: having those here should allow
     // 1) Requesting them earlier as if they are @import'ed
     // 2) Allow bundling
     // fp> I am not 100% sure though. Comments welcome :)
     /*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( 'item.css', 'relative' );
     		require_css( 'style.css', 'relative' );*/
     // 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');
     }
     require_css('basic_styles.css', 'blog');
     // the REAL basic styles
     require_css('basic.css', 'blog');
     // Basic styles
     require_css('style.css', 'relative');
     require_js('js/core.js', 'relative');
     require_js('navigation.js', 'blog');
 }
開發者ID:ldanielz,項目名稱:uesp.blog,代碼行數:32,代碼來源:_skin.class.php

示例4:

    /**
     * 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');
        }
    }
開發者ID:b2evolution,項目名稱:pixel_skin,代碼行數:39,代碼來源:_skin.class.php

示例5:

 /**
  * 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', 'relative');
     require_js('ajax.js', 'blog');
     require_js('functions.js');
     require_js('rollovers.js');
     skin_content_header();
     // Sets charset!
     require_js('jquery-1.2.3.min.js');
     require_js('jquery.easing.min.js');
     require_js('jquery.lavalamp.min.js');
     // 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');
     }
 }
開發者ID:b2evolution,項目名稱:berona_skin,代碼行數:33,代碼來源:_skin.class.php

示例6: 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);
        }
    }
開發者ID:b2evolution,項目名稱:evopress_skin,代碼行數:30,代碼來源:_skin.class.php

示例7:

 /**
  * 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.
     require_css('item.css', 'relative');
 }
開發者ID:b2evolution,項目名稱:evocamp_skin,代碼行數:12,代碼來源:_skin.class.php

示例8:

    /**
     * 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', 'relative');
        // 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');
        }
        add_headline('<link rel="stylesheet" href="rsc/css/style.css" type="text/css" />
					   <link rel="alternate stylesheet" href="rsc/css/red.css" type="text/css" title="red" />
		<link rel="alternate stylesheet" href="rsc/css/blue.css" type="text/css" title="blue" />
		<link rel="alternate stylesheet" href="rsc/css/green.css" type="text/css" title="green" />
		<link rel="alternate stylesheet" href="rsc/css/brown.css" type="text/css" title="brown" />
		<link rel="alternate stylesheet" href="rsc/css/magenta.css" type="text/css" title="magenta" />');
        // Add custom CSS:
        $custom_css = '';
        $skincolor = $this->get_setting('skin_color');
        $widthstyle = '';
        $html5support = '';
        if ($this->get_setting('width_style') == 'fixed') {
            // Fixed Layout
            $widthstyle .= 'width: 950px !important; /* fixed */';
        }
        if ($this->get_setting('width_style') == 'fluid') {
            // Fluid Layout
            $widthstyle .= 'width: 90% !important; /* fluid */';
        }
        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 . '
		<link rel="stylesheet" href="rsc/css/' . $skincolor . '.css" type="text/css" title="' . $skincolor . '" />
		<style type="text/css">
		div.widthstyle {
			' . $widthstyle . '
		}
		</style>
		';
        add_headline($custom_css);
    }
開發者ID:b2evolution,項目名稱:nonzero_skin,代碼行數:62,代碼來源:_skin.class.php

示例9:

 /**
  * 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_js_headline('var touch_skin_switch_confirm_text = "' . TS_('Switch to regular view? \\n \\n You can switch back again in the footer.') . '";');
     $this->require_js('js/core.js');
     require_js('navigation.js', 'blog');
 }
開發者ID:b2evolution,項目名稱:touch_skin,代碼行數:14,代碼來源:_skin.class.php

示例10: array

    /**
     * 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";
        }
        if (!empty($custom_css)) {
            $custom_css = '<style type="text/css">
	<!--
' . $custom_css . '	-->
	</style>';
            add_headline($custom_css);
        }
    }
開發者ID:b2evolution,項目名稱:photoblog_skin,代碼行數:59,代碼來源:_skin.class.php

示例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; }');
     }
 }
開發者ID:Ariflaw,項目名稱:b2evolution,代碼行數:17,代碼來源:_skin.class.php

示例12: and

    /**
     * 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);
        }
    }
開發者ID:b2evolution,項目名稱:bg_skin,代碼行數:50,代碼來源:_skin.class.php

示例13:

    /**
     * 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);
        }
    }
開發者ID:b2evolution,項目名稱:dating_mood_skin,代碼行數:24,代碼來源:_skin.class.php

示例14:

    /**
     * Get ready for displaying the skin.
     *
     * This may register some CSS or JS...
     */
    function display_init()
    {
        global $disp;
        // call parent:
        parent::display_init();
        // We pass NO params. This gives up the default Skins API v5 behavior.
        // Add custom CSS:
        $custom_css = '';
        if ($color = $this->get_setting('head_bg_color')) {
            // Custom Header background color:
            $custom_css .= '	div.pageHeader { background-color: ' . $color . " }\n";
        }
        if ($color = $this->get_setting('head_text_color')) {
            // Custom Header text color:
            $custom_css .= '	div.pageHeader, div.pageHeader a { color: ' . $color . " }\n";
        }
        if ($color = $this->get_setting('menu_bg_color')) {
            // Custom Menu background color:
            $custom_css .= '	div.top_menu_bg { background-color: ' . $color . " }\n";
        }
        if ($color = $this->get_setting('menu_text_color')) {
            // Custom Menu text color:
            $custom_css .= '	div.top_menu a { color: ' . $color . " }\n";
        }
        if ($color = $this->get_setting('footer_bg_color')) {
            // Custom Footer background color:
            $custom_css .= '	div#pageFooter { background-color: ' . $color . " }\n";
        }
        if (!empty($custom_css)) {
            $custom_css = '<style type="text/css">
	<!--
' . $custom_css . '	-->
	</style>';
            add_headline($custom_css);
        }
        // Functions to switch between the width sizes
        require_js('#jquery#', 'blog');
        require_js('widthswitcher.js', 'blog');
        if (in_array($disp, array('single', 'page', 'comments'))) {
            // Load jquery UI to animate background color on change comment status or on vote
            require_js('#jqueryUI#', 'blog');
        }
    }
開發者ID:Ariflaw,項目名稱:b2evolution,代碼行數:48,代碼來源:_skin.class.php

示例15:

 /**
  * 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', 'relative');
     // 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');
     }
 }
開發者ID:b2evolution,項目名稱:bluer_skin,代碼行數:25,代碼來源:_skin.class.php


注:本文中的Skin::display_init方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。