ID); foreach ($anc as $ancestor) { if (is_page() && $ancestor == $pid) { return true; } } if (is_page() && (is_page($pid))) return true; // we’re at the page or at a sub page else return false; // we’re elsewhere } ; //IE Compatibility Fix add_filter('wp_headers', 'cdfie_add_header'); function cdfie_add_header($headers) { $headers['X-UA-Compatible'] = 'IE=edge,chrome=1'; return $headers; } ; //CUSTOM POST TYPES include_once('includes/customposttypes.php'); //CUSTOM TAXONOMIES include_once('includes/customtaxonomies.php'); //CUSTOM META include_once('includes/meta.php'); //include_once('includes/event_meta.php'); //THIRD PARTY INTERFACES include_once('includes/thirdparty.php'); //UTILITY & MISC FUNCTIONS include_once('includes/utility_funcs.php'); //WC AJAX include_once('includes/wc-ajax.php'); // Custom Admin CSS function custom_get_cloud_css_admin() { echo ''; } function url_get_contents($Url) { if (!function_exists('curl_init')) { die('CURL is not installed!'); } $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $Url); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $output = curl_exec($ch); curl_close($ch); return $output; } ; // Registers admin menu separators add_action('admin_menu', 'admin_menu_separator'); // Create Admin Menu Separator function add_admin_menu_separator($position) { global $menu; $index = 0; foreach ($menu as $offset => $section) { if (substr($section[2], 0, 8) == 'separator') $index++; if ($offset >= $position) { $menu[$position] = array('', 'read', "separator{$index}", '', 'wp-menu-separator'); break; } } ksort($menu); } ; // Adds Admin Menu Separators function admin_menu_separator() { // Add custom separator after comments add_admin_menu_separator(29); } ; // For Featured Post function register_post_assets() { add_meta_box('featured-post', __('Featured Post'), 'add_featured_meta_box', 'post', 'advanced', 'high'); } add_action('admin_init', 'register_post_assets', 1); function add_featured_meta_box($post) { $featured = get_post_meta($post->ID, '_featured-post', true); echo ""; echo ""; } // To save or update the checkbox value function save_featured_meta($post_id) { if (isset($_REQUEST['featured-post'])) update_post_meta(esc_attr($post_id), '_featured-post', esc_attr($_REQUEST['featured-post'])); } add_action('save_post', 'save_featured_meta'); require('functions-ms-upgrade.php'); // To manually add disqus comments to non-blog posts function disqus_embed($disqus_shortname) { global $post; wp_enqueue_script('disqus_embed', 'http://' . $disqus_shortname . '.disqus.com/embed.js'); echo '
'; } add_action('admin_head', 'metabox_thickbox_bar_fix'); function metabox_thickbox_bar_fix() { echo ' '; }

<? the_title();?>
0 comments