本文整理汇总了PHP中theme::part方法的典型用法代码示例。如果您正苦于以下问题:PHP theme::part方法的具体用法?PHP theme::part怎么用?PHP theme::part使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类theme
的用法示例。
在下文中一共展示了theme::part方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
theme::options_update_data();
?>
<section class="ui tab active" data-tab="first">
<?php
theme::part('content-general', 'content', 'theme-options-general');
?>
</section>
<section class="ui tab" data-tab="second">
<?php
theme::part('content-meta-tags', 'content', 'theme-options-meta-tags');
?>
</section>
<section class="ui tab" data-tab="third">
<?php
theme::part('content-about', 'content', 'theme-options-about');
?>
</section>
<br>
<div class="ui buttons">
<a class="ui button" href="<?php
echo theme::options_uri();
?>
">Cancel</a>
<button type="submit" class="ui positive submit button">Save All</button>
</div>
</form>
</div>
示例2:
<div id="theme-options-page" class="ui basic segment" style="max-width:99%;">
<h1 class="ui huge header">
Theme Options
</h1>
<?php
theme::part('content', 'content', 'theme-options');
?>
</div>
示例3:
<?php
/**
* The Footer (view)
*/
?>
<div class="ui unstackable grid">
<div class="eight wide column">
<a href="https://github.com/Project-CleverWeb/LastAutoIndex">
Source Code on Github
</a>
</div>
<div class="eight wide right aligned column" id="copyright">
© Nicholas Jordon 2015 – All Rights Reserved
</div>
</div>
<?php
theme::part('modals', 'content');
if (isset($_GET['debug'])) {
theme::output_debug();
}
示例4: printf
</a>
<?php
}
if (lastautoindex::$login->is_logged_in) {
?>
<a class="item">
Options <i class="settings icon"></i>
</a>
<?php
}
?>
<div class="right menu">
<div class="text item">
<?php
$listing = theme::$dir;
if (theme::$search) {
$listing = (object) theme::$search;
}
printf('%1$s Items | %2$s Folders | %3$s Files', count($listing->items), count($listing->folders), count($listing->files));
?>
</div>
</div>
</div>
<div class="ui fluid left icon input" id="directory-index-filter-container">
<input id="directory-index-filter" type="text" placeholder="Start typing to filter">
<i class="filter icon"></i>
</div>
<?php
theme::part('index', 'content');
theme::part('readme', 'content');
示例5: get_header
<?php
/**
* The "Sidebar: None" Layout
*
* This layout has no sidebars
*/
get_header();
?>
<main>
<?php
theme::part('loop', 'content', 'loop', get_post_format());
?>
</main>
<?php
get_footer();
示例6: dev_notes_page
/**
* Displays the options page content when called
*
* @return void
*/
public function dev_notes_page()
{
theme::part('template', 'template', 'dev-notes');
}
示例7:
<?php
/**
* Display a standard page with the loop replaced by the 404 page content
*/
theme::use_part('loop', 'content', '404');
theme::part('template', 'template', 'default');
示例8: define
<?php
/**
* Default Theme File (required/view)
* ==================================
* This is the only required file for a valid theme. Everything else is left up
* to the theme's developer.
*
* If you are confused on how this theme works, you should see the following
* files and read their code comments: (relative to this themes root directory)
* - readme.md
* - config.php
* - includes/autoload.php
* - includes/classes/main.php
* - includes/classes/display_index.php
* - includes/classes/display_search.php
*/
if (!class_exists('lastautoindex', FALSE)) {
define('LAI_ALLOW_MULTI_INDEX', TRUE, 1);
require_once __DIR__ . '/../../index.php';
} else {
theme::part('index', 'template');
}
示例9:
<?php
/**
* The header. Always use the_header() to make sure WordPress hooks are
* always correctly called.
*
* @package Semanitic UI for WordPress
*/
theme::part('header', 'content', 'header');
示例10:
<?php
theme::part('modals/image', 'content');
示例11:
<?php
/*
Template Name: First-Run
*/
theme::use_part('header', 'content', 'header', 'none');
theme::part('layout', 'layout', 'first-run');
示例12: get_header
get_header();
?>
<main>
<div class="empty size-10"> </div>
<h1 class="ui center aligned dividing header">
Welcome to Semantic UI for WordPress!
<?php
if (current_user_can('edit_theme_options')) {
?>
<div class="sub header">This is the first-run page, you can disable it from the <a href="<?php
echo theme::options_uri();
?>
">Theme Options</a> page.</div>
<?php
} else {
?>
<div class="sub header">This is the first-run page, <strong>once you login</strong>, you can disable it from the Theme Options page.</div>
<?php
}
?>
</h1>
<div class="ui basic segment">
<?php
theme::part('content', 'content', 'first-run');
?>
</div>
</main>
<?php
get_footer();
示例13: exit
* Directory Index Template (view)
* ===============================
* This is the template that is used under normal conditions. It shows the
* contents of the current directory that the user has browsed to.
*
* NOTE: For every "index.php" file in your theme, you should give a 'forbidden'
* message of some sort, like below.
*/
if (!class_exists('lastautoindex', FALSE)) {
exit("Forbidden: This directory/file cannot be accessed directly");
}
// Queue this template's specific styles & scripts
theme::queue_style('font-awesome');
theme::queue_style('webicons');
theme::queue_style('semantic');
theme::queue_style('highlight-js');
theme::queue_style('main');
theme::queue_script('jquery');
theme::queue_script('modernizr');
theme::queue_script('moustrap');
theme::queue_script('highlight-js');
theme::queue_script('semantic');
theme::queue_script('tablesort');
theme::queue_script('main');
// If the page has a readme section, then load the styles for that too.
if (theme::has_readme()) {
theme::queue_style('readme');
}
// Headers should have been sent already so we can start printing the page.
theme::part('default', 'layout');
示例14:
5.0 - Recommendations
</a>
<div class="content menu">
<a class="item">5.1 - Rec 1</a>
<a class="item">5.2 - Rec 2</a>
<a class="item">5.3 - Rec 3</a>
</div>
</div>
</div>
</div>
<div class="twelve wide column">
<?php
theme::part('content', 'content', 'dev-notes');
?>
</div>
</div>
</div>
<script>
// A little script to make the nav menu scroll with the page
jQuery(document).ready(function(){
jQuery(this).scroll(function() {
if (jQuery(this).scrollTop() > 105 && jQuery(this).width() >= 770) {
jQuery('#notes-menu').css('margin-top', (jQuery(this).scrollTop() - 105));
} else {
jQuery('#notes-menu').css('margin-top', 0);
}
});
// If on mobile, no scroll, just sit at the top
示例15:
<?php
/**
* Install Template (view)
* =======================
* This is LastAutoIndex's installer, feel free to delete this template after
* installation.
*/
// Queue this template's specific styles & scripts
theme::queue_style('font-awesome');
theme::queue_style('webicons');
theme::queue_style('semantic');
theme::queue_style('highlight-js');
theme::queue_style('main');
theme::queue_script('jquery');
theme::queue_script('modernizr');
theme::queue_script('moustrap');
theme::queue_script('highlight-js');
theme::queue_script('semantic');
theme::queue_script('tablesort');
theme::queue_script('main');
// Headers should have been sent already so we can start printing the page.
theme::part('install', 'layout');