add_menu( array( 'id' => 'theme_options', 'title' => ' Alhena Options ', 'href' => get_admin_url() . 'themes.php?page=themeoption' ) ); $wp_admin_bar->add_menu( array( 'id' => 'get_premium', 'title' => ' Get Premium ', 'href' => get_admin_url() . 'themes.php?page=getpremium' ) ); } add_action( 'admin_bar_menu', 'wip_option_panel', 1000 ); /*-----------------------------------------------------------------------------------*/ /* Content width */ /*-----------------------------------------------------------------------------------*/ if ( ! isset( $content_width ) ) $content_width = 940; /*-----------------------------------------------------------------------------------*/ /* Prettyphoto at post gallery */ /*-----------------------------------------------------------------------------------*/ function wip_prettyPhoto( $html, $id, $size, $permalink, $icon, $text ) { if ( ! $permalink ) return str_replace( 'ID); endif; return ' ' . __( "Read More","wip") . ' '; } add_filter('excerpt_more', 'wip_new_excerpt_more'); /*-----------------------------------------------------------------------------------*/ /* Shortcode in widget */ /*-----------------------------------------------------------------------------------*/ add_filter('widget_text', 'do_shortcode'); /*-----------------------------------------------------------------------------------*/ /* Remove category list rel */ /*-----------------------------------------------------------------------------------*/ function wip_remove_category_list_rel($output) { $output = str_replace('rel="category"', '', $output); return $output; } add_filter('wp_list_categories', 'wip_remove_category_list_rel'); add_filter('the_category', 'wip_remove_category_list_rel'); /*-----------------------------------------------------------------------------------*/ /* Remove thumbnail dimensions */ /*-----------------------------------------------------------------------------------*/ function wip_remove_thumbnail_dimensions( $html, $post_id, $post_image_id ) { $html = preg_replace( '/(width|height)=\"\d*\"\s/', "", $html ); return $html; } add_filter( 'post_thumbnail_html', 'wip_remove_thumbnail_dimensions', 10, 3 ); /*-----------------------------------------------------------------------------------*/ /* Remove css gallery */ /*-----------------------------------------------------------------------------------*/ function wip_my_gallery_style() { return "