function bfox_ajax_send_bible_text()
{
    sleep(1);
    set_bfox_ref(new BfoxRef($_POST['ref_str']));
    ob_start();
    load_bfox_template('admin-bfox_tool');
    $content = ob_get_clean();
    $content = addslashes(str_replace("\n", '', $content));
    $script = "bfox_quick_view_loaded('{$ref_str}', '{$content}');";
    die($script);
}
예제 #2
0
function bfox_plan_do_feed_readings()
{
    if (is_single()) {
        global $post;
        if ('bfox_plan' == $post->post_type) {
            $feed = get_query_var('feed');
            if ('readings-rss' == $feed) {
                load_bfox_template('rss-bfox_plan');
            } else {
                if ('readings-ical' == $feed) {
                    load_bfox_template('ical-bfox_plan');
                }
            }
        }
    }
}
예제 #3
0
function bfox_bp_before_bible_directory_activity_content()
{
    $ref = bfox_ref();
    $search_value = $ref->get_string(BibleMeta::name_short);
    ?>
		<form action="<?php 
    echo get_post_type_archive_link('bfox_tool');
    ?>
" method="get" id="bible-directory-form" class="dir-form">
			<h3><?php 
    _e('Bible Reader', 'bfox');
    ?>
</h3>
			<div id="bible-dir-search" class="dir-search no-ajax">
				<?php 
    bfox_bp_bible_directory_search_form($search_value, __('Go to passage', 'bfox'));
    ?>
			</div><!-- #group-dir-search -->
		</form>
		<h4><?php 
    echo bfox_ref_str();
    ?>
</h4>
		<div class="bfox-tool-bp-bible">
			<div id="bfox-bible-container">
				<?php 
    load_bfox_template('content-bfox_tool');
    ?>
			</div>
		</div>
	<?php 
}
예제 #4
0
function bfox_tool_template_redirect($template)
{
    if ('bfox_tool' == get_query_var('post_type')) {
        if (is_singular('bfox_tool')) {
            load_bfox_template('single-bfox_tool');
            exit;
        }
        if (is_archive()) {
            load_bfox_template('archive-bfox_tool');
            exit;
        }
    }
}
예제 #5
0
<?php

/**
 * The template for displaying Bible tooltips.
 *
 * Just displays the Bible Tool iFrame
 *
 */
?>

<div class="bfox-tooltip">
	<?php 
load_bfox_template('iframe-bfox_tool');
?>
</div>
예제 #6
0
<?php

/**
 * The template for displaying Bible Tools within the admin interface (ie. on Edit Post screen)
 *
 */
if (!empty($_REQUEST['src'])) {
    ?>
	<?php 
    echo bfox_tool_content_for_ref(new BfoxRef($_REQUEST['ref']));
} else {
    ?>
	<?php 
    load_bfox_template('archive-bfox_tool');
}
예제 #7
0
			<select class="bfox-tool-name" id="bfox-tool-name-main" name="tool"><?php 
    echo bfox_tool_select_options();
    ?>
</select>
			<input type="submit" class="submit" value="<?php 
    esc_attr_e('Go');
    ?>
" />
		</form>

		<div class="depends-bfox-tool-ref-global depends-bfox-tool-name-main" data-url="<?php 
    echo bfox_tool_context_ajax_url('main');
    ?>
">
			<?php 
    load_bfox_template('content-bfox_tool');
    ?>
		</div>

	<?php 
} else {
    ?>

		<article id="post-0" class="post no-results not-found">
			<header class="entry-header">
				<h1 class="entry-title"><?php 
    _e('Bible Tool Not Found');
    ?>
</h1>
			</header><!-- .entry-header -->
예제 #8
0
/**
 * Creates the form displaying the scripture quick view
 *
 */
function bfox_blog_quick_view_meta_box()
{
    global $post_ID;
    $ref = bfox_blog_post_get_ref($post_ID);
    if (!empty($_REQUEST['bfox_ref'])) {
        $ref->add_string($_REQUEST['bfox_ref']);
    }
    $is_valid = $ref->is_valid();
    if ($is_valid) {
        $ref_str = $ref->get_string();
    }
    set_bfox_ref($ref);
    // Create the form
    load_bfox_template('edit_post-bfox_tool');
}