コード例 #1
0
ファイル: functions.php プロジェクト: TwoBeers/shiword
 function shiword_content_class($class = array())
 {
     if (!empty($class)) {
         if (!is_array($class)) {
             $class = preg_split('#[\\s,]+#', $class);
         }
     }
     if ((is_archive() || is_home() || is_search() || is_front_page() && get_option('show_on_front') == 'posts') && shiword_get_opt('shiword_pthumb')) {
         $class[] = 'sw-has-thumb';
     }
     $class[] = 'posts_' . shiword_get_layout();
     $class = array_map('esc_attr', $class);
     $class = apply_filters('shiword_content_class', $class);
     echo join(' ', $class);
 }
コード例 #2
0
ファイル: page.php プロジェクト: TwoBeers/shiword
<?php

/**
 * page.php
 *
 * The single page template file, used to display single pages.
 *
 * @package Shiword
 * @since 1.00
 */
get_header();
?>

<?php 
shiword_get_layout('page');
?>

<div id="posts-container" class="<?php 
shiword_content_class();
?>
">

	<?php 
if (have_posts()) {
    while (have_posts()) {
        the_post();
        ?>

			<?php 
        shiword_hook_entry_before();
        ?>
コード例 #3
0
ファイル: one-column-page.php プロジェクト: TwoBeers/shiword
<?php

/**
 * Template Name: One column, no sidebar
 *
 * A custom page template without sidebar.
 *
 * @package Shiword
 * @since 2.06
 */
get_header();
?>

<?php 
shiword_get_layout('one-column');
?>

<div id="posts-container" class="<?php 
shiword_content_class();
?>
">

	<?php 
if (have_posts()) {
    while (have_posts()) {
        the_post();
        ?>

			<?php 
        shiword_hook_entry_before();
        ?>
コード例 #4
0
ファイル: allcat.php プロジェクト: TwoBeers/shiword
<?php

/**
 * allcat.php
 *
 * The template file used to display the whole category list 
 * as a page.
 *
 * @package Shiword
 * @since 1.00
 */
get_header();
?>

<?php 
shiword_get_layout();
?>

<div class="<?php 
shiword_content_class();
?>
">

	<div class="post">

		<h2 class="storytitle"><?php 
_e('Categories', 'shiword');
?>
</h2>

		<div class="meta_container">
コード例 #5
0
ファイル: single.php プロジェクト: TwoBeers/shiword
<?php

/**
 * single.php
 *
 * The single blog post template file, used to display single blog posts.
 *
 * @package Shiword
 * @since 1.00
 */
get_header();
?>

<?php 
shiword_get_layout('post');
?>

<div id="posts-container" class="<?php 
shiword_content_class();
?>
">

	<?php 
if (have_posts()) {
    while (have_posts()) {
        the_post();
        ?>

			<?php 
        shiword_navlinks();
        ?>
コード例 #6
0
ファイル: attachment.php プロジェクト: TwoBeers/shiword
<?php

/**
 * attachment.php
 *
 * Template for attachment pages
 *
 * @package Shiword
 * @since 1.00
 */
get_header();
?>

<?php 
shiword_get_layout('attachment');
?>

<div class="<?php 
shiword_content_class();
?>
">

<?php 
if (have_posts()) {
    while (have_posts()) {
        the_post();
        ?>

		<?php 
        shiword_hook_entry_before();
        ?>