Example #1
0
function vnl_include($template)
{
    switch ($template) {
        // page template
        case 'page':
            $file = cfct_default_file('pages');
            cfct_template_file('pages', $file);
            break;
            // content template
        // content template
        case 'content':
        case 'excerpt':
            $file = cfct_choose_content_template($template);
            cfct_template_file($template, $file);
            break;
            // comment template
        // comment template
        case 'comment':
            $file = cfct_choose_comment_template($template);
            cfct_template_file($template, $file);
            break;
            // forms template
        // forms template
        case 'comment-form':
        case 'search':
            cfct_template_file('forms', str_replace('-form', '', $template));
            break;
            // misc template
        // misc template
        case 'banner':
        case 'image':
        case 'nav-posts':
            cfct_template_file('misc', $template);
            break;
            // error template
        // error template
        case '404':
        case 'exit':
            cfct_template_file('error', $template);
            break;
            // general template (everything else!)
        // general template (everything else!)
        default:
            $file = cfct_choose_general_template($template);
            cfct_template_file($template, $file);
    }
}
Example #2
0
function cfct_error($name = '')
{
    cfct_template_file('error', $name);
}
Example #3
0
/**
 * Include a specific file based on directory and filename and return the output
 * 
 * @param string $dir Directory the file will be in
 * @param string $file Filename
 * @param array $data pass in data to be extracted for use by the template
 * 
**/
function cfct_template_content($dir, $file, $data = array())
{
    ob_start();
    cfct_template_file($dir, $file, $data);
    return ob_get_clean();
}
Example #4
0
    die;
}
if (CFCT_DEBUG) {
    cfct_banner(__FILE__);
}
if (have_posts()) {
    echo '<ol class="archive">';
    while (have_posts()) {
        the_post();
        ?>
	<li>
<?php 
        // image archive
        if (is_tax('post_format', 'post-format-image')) {
            cfct_template_file('excerpt', 'format-image-archive');
        } else {
            if (is_tax('post_format', 'post-format-video')) {
                cfct_template_file('excerpt', 'format-video-archive');
            } else {
                cfct_excerpt();
            }
        }
        ?>
		<div id="post-<?php 
        the_ID();
        ?>
-target"></div>
<?php 
    }
    echo '</ol>';
}
Example #5
0
?>
		</ul>
	</div>
	<div id="pages_tab">
		<hr />
		<h2 class="table-title" id="pages"><?php 
_e('Pages');
?>
</h2>
		<ul class="disclosure table group">
			<?php 
echo $sub_pages;
wp_list_pages('title_li=&depth=1');
?>
		</ul>
	</div>
</div>

<hr />

<p id="navigation-bottom" class="navigation">
	<?php 
cfct_misc('main-nav');
?>
</p>

<hr />

<?php 
cfct_template_file('footer', 'bottom');
Example #6
0
if (CFCT_DEBUG) {
    cfct_banner(__FILE__);
}
global $comment, $post;
// Extract data passed in from threaded.php for comment reply link
extract($data);
?>
<article <?php 
comment_class('reply');
?>
 id="comment-<?php 
comment_ID();
?>
">
	<?php 
cfct_template_file('comment', 'comment-header');
?>
	<div class="content">
		<?php 
if ($comment->comment_approved == '0') {
    echo '<p><b>' . __('Your comment is awaiting moderation.', 'anno') . '</b></p>';
}
comment_text();
?>
	</div><!-- .content -->
	<div class="footer">
		<?php 
comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])), $comment, $post);
edit_comment_link(__('Edit This', 'anno'), ' <span class="delimiter">&middot;</span> ', '');
?>
	</div><!-- .footer -->
        ?>
		</div>
		<div class="description">
			<?php 
        the_content();
        ?>
		</div>
	</div>

<?php 
        if (cfct_get_adjacent_image_link(false) != '') {
            echo '<div class="next-attachment"><span>', next_image_link(), '</span></div>';
        }
        if (cfct_get_adjacent_image_link(true) != '') {
            echo '<div class="previous-attachment"><span>', previous_image_link(), '</span></div>';
        }
        ?>
</div>

<?php 
    }
} else {
    cfct_template_file('misc', 'no-results.php');
}
?>

<?php 
wp_footer();
?>
</body>
</html>
Example #8
0
 * @package sdac
 * This file is where all the assets for the theme get added.
 *
 * It has two basic modes:
 * Production mode will enqueue the files built using the
 * command line PHP script in build/build.php (see README in the same folder).
 * Developer mode will load in the original, unminified CSS files for development.
 *
 * You can toggle between developer and production mode by setting SDAC_PRODUCTION true/false
 * in functions.php
 *
 * ALWAYS run build.php, turn off developer mode and commit result before deploying.
 */
// Using icky blog global to determine which assets to deliver for now.
global $blog;
cfct_template_file('assets', 'config');
if (!is_admin()) {
    $asset_url = trailingslashit(get_template_directory_uri());
    foreach (Bundler::$build_profiles as $bundler) {
        $asset_url_prefix = $asset_url;
        $bundles = $bundler->get_bundles();
        foreach ($bundles as $bundle) {
            if (CFCT_PRODUCTION) {
                enqueue_bundle($bundle->get_language(), $bundle->get_bundle_key(), $asset_url_prefix . $bundle->get_bundled_path(), $bundle->get_meta('dependencies'), CFCT_THEME_VERSION);
            } else {
                foreach ($bundle->get_bundle_items() as $bundle_item) {
                    enqueue_bundle($bundle->get_language(), $bundle_item->get_key(), $asset_url_prefix . $bundle_item->get_path(), $bundle->get_meta('dependencies'), CFCT_THEME_VERSION);
                }
            }
        }
    }
/**
 * Add theme CSS, JS here. Everything should run through the enqueue system so that
 * child themes/plugins have access to override whatever they need to.
 * Run at 'wp' hook so we have access to conditional functions, like is_single(), etc.
 */
function anno_assets()
{
    cfct_template_file('assets', 'load');
}
Example #10
0
?>
" type="text/css" media="all">
</head>

<body <?php 
body_class();
?>
>
	<div id="header">
		<?php 
echo Anno_PDF_Download::header_markup();
?>
	</div>
	<div id="main" class="act">
		<div class="in">
		
			<div id="main-body" class="clearfix">
				
				<?php 
cfct_template_file('content', 'article-pdf');
?>
				
			</div><!-- #main-content -->

		</div><!-- .in -->
	</div><!-- #main -->
	<?php 
echo Anno_PDF_Download::footer_markup();
?>
</body>
</html>
Example #11
0
function cfcp_header_display_image()
{
    cfct_template_file('header', 'featured-image');
}
Example #12
0
			</fieldset>
		
			<fieldset>
				<div class="cf-elm-block">
					<label class="typ-sc"><?php 
_e('Links', 'favepersonal');
?>
</label>
					<div class="cfp-list-img-left cf-clearfix">
						<ul id="cfp-link-items">
						<?php 
echo '<li class="no-link-item' . (empty($settings['links']) ? '' : ' cf-hidden') . '"><p>' . __('Click the "+" to the right to start adding links', 'favepersonal') . '</p></li>';
if (!empty($settings['links']) && is_array($settings['links'])) {
    foreach ($settings['links'] as $link) {
        if (is_array($link)) {
            cfct_template_file('functions/about/views', 'link-item', compact('link'));
        }
    }
}
?>
						</ul>
					</div><!--.cfp-link-->
					<a href="#cfp-link-edit-popover" class="cfp-add-link" id="cfp-add-link"><?php 
_e('Add', 'favepersonal');
?>
</a>
				</div>
			</fieldset>
			
			<p class="submit"><input class="button button-primary" type="submit" name="submit" value="<?php 
_e('Save Settings', 'favepersonal');
Example #13
0
/**
 * Load in assets at wp_enqueue_scripts hook
 * This function loads a file that contains calls to wp_enqueue_script
 * and wp_enqueue_style, etc.
 */
function cfct_load_front_end_assets()
{
    cfct_template_file('assets', 'load');
}
Example #14
0
<p><?php 
    printf(__('Stay in touch with the conversation, subscribe to the <a class="feed" rel="alternate" href="%s"><acronym title="Really Simple Syndication">RSS</acronym> feed for comments on this post</a>.', 'carrington-blog'), get_post_comments_feed_link($post->ID, ''));
    ?>
</p>

<?php 
    if ($comments) {
        $comment_count = 0;
        $ping_count = 0;
        foreach ($comments as $comment) {
            if (get_comment_type() == 'comment') {
                $comment_count++;
            } else {
                $ping_count++;
            }
        }
        if ($comment_count) {
            cfct_template_file('comments', 'comments-loop');
        }
        if ($ping_count) {
            ?>
<h3 class="pings"><?php 
            _e('Continuing the Discussion', 'carrington-blog');
            ?>
</h3>
<?php 
            cfct_template_file('comments', 'pings-loop');
        }
    }
    cfct_form('comment');
}
Example #15
0
<?php

// This file is part of the Carrington Blog Theme for WordPress
// http://carringtontheme.com
//
// Copyright (c) 2008-2010 Crowd Favorite, Ltd. All rights reserved.
// http://crowdfavorite.com
//
// Released under the GPL license
// http://www.opensource.org/licenses/gpl-license.php
//
// **********************************************************************
// This program is distributed in the hope that it will be useful, but
// WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
// **********************************************************************
if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) {
    die;
}
if (CFCT_DEBUG) {
    cfct_banner(__FILE__);
}
cfct_template_file('loop', 'single');
Example #16
0
//
// Released under the GPL license
// http://www.opensource.org/licenses/gpl-license.php
//
// **********************************************************************
// This program is distributed in the hope that it will be useful, but
// WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
// **********************************************************************
if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) {
    die;
}
if (CFCT_DEBUG) {
    cfct_banner(__FILE__);
}
if (have_posts()) {
    echo '<ol class="archive">';
    while (have_posts()) {
        the_post();
        ?>
	<li class="search">
<?php 
        cfct_template_file('excerpt', 'search');
        ?>
	</li>
<?php 
    }
    echo '</ol>';
} else {
    cfct_misc('no-results');
}
</title>

	<link rel="stylesheet" id="anno-pdf-css"  href="<?php 
echo esc_url(trailingslashit(get_template_directory_uri()) . 'assets/main/css/pdf.css?ver=1.1');
?>
" type="text/css" media="all">
</head>

<body <?php 
body_class();
?>
>
	
	<div id="main" class="act">
		<div class="in">
		
			<div id="main-body" class="clearfix">
				
				<?php 
cfct_template_file('content', 'type-article');
?>
				
			</div><!-- #main-content -->

		</div><!-- .in -->
	</div><!-- #main -->
	<?php 
wp_footer();
?>
</body>
</html>