ID == '1') {$vtrace = true;}
return $vtrace;
}
// /====================
// === Theme Options ===
// ====================/
// options_theme_options
// options_framework_menu
// options_submenu_position
// options_admin_menu_title
// options_admin_menu_position
// options_admin_menu_icon
// options_themepage_styles
// options_images_url
// options_font_stacks
// options_title_fonts
// /=======================/
// /= Available Theme Options =/
// -----------------------------
add_filter('options_theme_options','muscle_options_theme_options');
function muscle_options_theme_options($voptions) {
// modify available theme options array conditionally
return $voptions;
}
// /= Change Appearance Submenu =/
// -------------------------------
// (for Options Framework only)
// 2.0.9: renamed filter for consistency using compat.php
add_filter('options_framework_menu','muscle_options_submenu',1);
function muscle_options_submenu($vmenu) {
// Default
// $vmenu = array(
// 'mode' => 'submenu',
// 'page_title' => __( 'Theme Options', 'bioship'),
// 'menu_title' => __('Theme Options', 'bioship'),
// 'capability' => 'edit_theme_options',
// 'menu_slug' => 'options-framework',
// 'parent_slug' => 'themes.php',
// );
// Example: Change "Theme Options" submenu title to Child Theme name
# if (is_child_theme()) {
# global $vtheme, $wp_version;
# if (get_bloginfo('version') < '3.4') {$vchildtheme = get_theme_data(get_stylesheet_directory($vtheme).'/style.css');}
# else {$vchildtheme = wp_get_theme($vtheme);}
# if ($vchildtheme['Name'] != '') {$vmenu['page_title'] = $vmenu['menu_title'] = $vchildtheme['Name'].' Options';}
# }
// Note: Position must be changed separately (as not available via add_submenu_page)
// Warning: Do NOT change the menu_slug value! just in case:
$vmenu['menu_slug'] = "options-framework";
return $vmenu;
}
// /= Change Submenu Position =/
// -----------------------------
add_filter('options_submenu_position','muscle_options_submenu_position');
function muscle_options_submenu_position($vposition) {
// default 1 (first in Appearance menu)
# $vposition = '6'; // moves below Themes in Appearance menu
return $vposition;
}
// /= Add Main Theme Menu =/
// -------------------------
// (for Options Framework only - as off by default)
add_filter('muscle_theme_options_menu','muscle_add_theme_options_menu');
function muscle_add_theme_options_menu($vmenu) {
// ref: https://codex.wordpress.org/Function_Reference/add_menu_page
// note: by default, Options Framework does NOT add this page
// default
// $vmenu = array(
// 'mode' => 'menu',
// 'page_title' => __( 'Theme Options', 'bioship'),
// 'menu_title' => __('Theme Options', 'bioship'),
// 'capability' => 'edit_theme_options',
// 'parent_slug' => 'themes.php',
// 'icon_url' => 'dashicons-admin-generic',
// 'position' => '59'
// );
// change the menu icon URL
# global $vthemedirs;
# $vicon = bioship_file_hierarchy('url','theme-options-icon.png',$vthemedirs['image']);
# if ($vicon) {$vmenu['icon_url'] = $vicon;}
// change the menu position
# if (is_admin()) {$vposition = '61';} // after 'Appearance' for admin
# if (is_network_admin()) {$vposition = '29';} // above 'Updates' for network admin
return $vmenu;
}
// /= Options Admin Menu Title =/
// ------------------------------
// 1.8.0: for Titan Framework Main Menu
add_filter('options_admin_menu_title','muscle_admin_menu_title');
function muscle_admin_menu_title($vtitle) {
// default menu title is 'BioShip Options'
# $vtitle = 'Theme Options';
return $vtitle;
}
// /= Options Admin Menu Title =/
// ------------------------------
// 1.8.0: for Titan Framework Main Menu
add_filter('options_admin_menu_position','muscle_admin_menu_position');
function muscle_admin_menu_position($vposition) {
// default position is 60
# $vposition = 5;
return $vposition;
}
// /= Options Admin Menu Icon =/
// -----------------------------
// 1.8.0: for Titan Framework Main Menu
// ref: http://calebserna.com/dashicons-cheatsheet/
add_filter('options_admin_menu_icon','muscle_admin_menu_icon');
function muscle_admin_menu_icon($vicon) {
// default menu icon is 'dashicon-welcome-view-site'
# $vicon = 'dashicon-admin-appearance';
return $vicon;
}
// /= Theme Options Styling =/
// ---------------------------
add_filter('options_themepage_styles','muscle_options_themepage_styles');
function muscle_options_themepage_styles($vstyles) {
// add some extra styling to the Theme Options page
# $vstyles .= ".filterbutton {font-size:12pt; font-weight:bold;}";
return $vstyles;
}
// /= Options Page Images Path =/
// ------------------------------
// for changing image radio buttons path
add_filter('options_images_url','muscle_options_images_url');
function muscle_options_images_url($vpath) {
// eg. change to child theme images directory
# $vpath = get_stylesheet_directory_uri.'/images/';
return $vpath;
}
// /= Font Stack Options =/
// ------------------------
add_filter('options_font_stacks','muscle_font_stacks');
function muscle_font_stacks($vfonts) {
// Here you can replace existing font stacks or add your own
// Format: $vfonts['font1,font2,font3'] = 'DisplayName 1, Display Name 2, Display Name 3';
// eg1. (add):
# $vfonts['"PT Sans",helvetica,arial'] = 'PT Sans, Helvetica, Arial';
// eg2. (replace):
# unset($vfonts['helvetica, arial, "Nimbus Sans L", sans-serif']);
# $vfonts['"Open Sans", helvetica, arial, "Nimbus Sans L", sans-serif'] = 'Open Sans, Helvetica, Arial, Nimbus Sans L, sans-serif';
return $vfonts;
}
// /= Title Font Options =/
// ------------------------
add_filter('options_title_fonts','muscle_title_fonts');
function muscle_title_fonts($vfonts) {
// Here you could add some title font options to the selector
// Loaded from the Google Fonts API: http://www.google.com/fonts
// remember to use + for spaces as in the following example
# $vfonts['Special+Font'] = 'Special Font';
return $vfonts;
}
// /= Theme Recommendations =/
// ---------------------------
add_filter('options_recommendations','muscle_options_recommendations');
function muscle_options_recommendations($vrecommend) {
// Add to the recommendations for this theme
# $vrecommend .= 'Another Awesome Plugin.';
// or even add a panel via a shortcode
# $vpanel = do_shortcode('[feed-panel]')
# return $vpanel.$vrecommend;
return $vrecommend;
}
// /=================
// === Customizer ===
// =================/
// options_customizer_split_options
// options_customizer_extra_styles
// options_customizer_logo_image
// options_customizer_description
// options_customizer_color_accent
// options_customizer_color_back
// options_customizer_panel_width
// /================/
// /= Customizer Split Options =/
add_filter('options_customizer_split_options','muscle_customizer_split_options');
function muscle_customizer_split_options($vsplit) {
// do not split customizer into 'basic' and 'advanced' pages
# $vsplit = false;
return $vsplit;
}
// /= Customizer Extra Styles =/
add_filter('options_customizer_extra_styles','muscle_customizer_extra_styles');
function muscle_customizer_extra_styles($vstyles) {
# TODO: example
return $vstyles;
}
// /= Customizer Logo Image =/
add_filter('options_customizer_logo_image','muscle_customizer_logo_image');
function muscle_customizer_logo_image($vimage) {
# TODO: example
return $vimage;
}
// /= Customizer Description =/
add_filter('options_customizer_description','muscle_customizer_description');
function muscle_customizer_description($vdescription) {
# TODO: example
return $vdescription;
}
// /= Customizer Colour Accent =/
add_filter('options_customizer_color_accent','muscle_customizer_color_accent');
function muscle_customizer_color_accent($vcolor) {
# TODO: example
return $vcolor;
}
// /= Customizer Sidebar Colour =/
add_filter('options_customizer_color_back','muscle_customizer_color_back');
function muscle_customizer_color_back($vcolor) {
# TODO: example
return $vcolor;
}
// /= Customizer Panel Width =/
add_filter('options_customizer_panel_width','muscle_customizer_panel_width');
function muscle_customizer_panel_width($vwidth) {
// Example: set panel width in em units
# $vwidth = '4em';
return $vwidth;
}
// /=============
// === HYBRID ===
// =============/
// hybrid_dirs
// hybrid_content_template_hierarchy
// skeleton_content_template_directory
// skeleton_archive_template_directory
// /============/
// ...see Hybrid docs for more available filters!
// /= Hybrid Directory =/
// ----------------------
add_filter('hybrid_dirs', 'muscle_hybrid_dirs');
function muscle_hybrid_dirs($vdirs) {
// paths to search for hybrid.php
return $vdirs;
}
// /= Content Template Hierarchy =/
// --------------------------------
// for advanced content template control
// see hybrid_get_content_template in hybrid/functions/template.php
add_filter('hybrid_content_template_hierarchy','muscle_content_template_hierarchy');
function muscle_content_template_hierarchy($vtemplates) {
// below is the default hybrid content template hierarchy for reference
# $vtemplates = array(); // optionally clear the hierarchy
# $vposttype = get_post_type(get_the_ID());
# if ($vposttype === 'attachment') {
# $vmimetype = get_post_mime_type();
# list( $type, $subtype ) = false !== strpos( $vmimetype, '/' ) ? explode( '/', $vmimetype ) : array($vmimetype, '' );
# $vtemplates[] = "content-attachment-{$vtype}.php";
# $vtemplates[] = "content/attachment-{$vtype}.php";
# }
# if (post_type_supports($vposttype,'post-formats')) {
# $vpostformat = get_post_format() ? get_post_format() : 'standard';
# $vtemplates[] = 'content-{$vposttype}-{$vpostformat}.php';
# $vtemplates[] = 'content/{$vposttype}-{$vpostformat}.php';
# $vtemplates[] = 'content-{$vpostformat}.php';
# $vtemplates[] = 'content/{$vpostformat}.php';
# }
# $vtemplates[] = 'content-{$vposttype}.php';
# $vtemplates[] = 'content/{$vposttype}.php';
# $vtemplates[] = 'content.php';
# $vtemplates[] = 'content/content.php';
return $vtemplates;
}
// /= Content Template Directory =/
// --------------------------------
// 1.9.5: added this filter for changing content template location
add_filter('skeleton_content_template_directory','muscle_content_template_directory');
function muscle_content_template_directory($vcontentdir) {
// Modify the /content/ location for content templates, default is 'content'
# $vcontentdir = 'singular';
return $vcontentdir;
}
// /= Archive Template Directory =/
// --------------------------------
// 1.9.5: added this filter for optional archive template location
add_filter('skeleton_archive_template_directory','muscle_archive_template_directory');
function muscle_archive_template_directory($varchivedir) {
// Modify the optional /archive/ location for archive templates, default is 'archive'
# $varchivedir = 'multlple';
return $varchivedir;
}
// /============
// === SKULL ===
// ============/
// skeleton_theme_hooks
// skeleton_site_icon
// skeleton_title_tag_support
// skeleton_page_title_tag
// skeleton_generator_meta
// skeleton_mobile_metas
// skeleton_apple_icons
// skeleton_startup_images
// skeleton_google_jquery_version
// /===========/
// note: browser and mobile detection filters:
// muscle_styles_* (auto-added)
// /= Theme Action Hooks =/
// ------------------------
// 2.0.9: added theme hook filtering (see hooks.php)
add_filter('skeleton_theme_hooks','muscle_theme_hooks');
function muscle_theme_hooks($vhooks) {
// allows for changing template hook order etc.
return $vhooks;
}
// /= Title Tag Theme Support =/
// -----------------------------
// 1.8.5: added title-tag theme support
add_filter('skeleton_title_tag_support','muscle_title_tag_support');
function muscle_title_tag_support($vsupport) {
// you can turn off theme title-tag support
// and fallback to use of filtered wp_title
# $vsupport = 0;
return $vsupport;
}
// /= Page Title Tag Filter =/
// ---------------------------
// 1.8.5: for wp_title fallback only
// You could remove the title filter eg. if your SEO plugin handles it
# remove_filter('wp_title','bioship_wp_title',10,2);
// or change the title
add_filter('skeleton_page_title_tag','muscle_page_title_tag');
function muscle_page_title_tag($vtitle) {
// Modify the existing title tag here, eg. for pages
# if (is_page()) {
# $vposttitle = get_the_title();
# $vblogname = esc_attr(get_bloginfo('name','display'));
# $vtitle = $vposttitle." | ".$vblogname;
# }
return $vtitle;
}
// /= Mobile Specific Metas =/
// ---------------------------
add_filter('skeleton_mobile_metas','muscle_mobile_metas');
function muscle_mobile_metas($vmobilemetas) {
// Add your own mobile meta tags
# $vmobilemetas .= '';
return $vmobilemetas;
}
// /= Change the Meta Generator Tag =/
// -----------------------------------
add_filter('skeleton_generator_meta','muscle_generator_meta');
function muscle_generator_meta($vmeta) {
// by default is removed entirely
# $vmeta = 'Custom Theme';
return $vmeta;
}
// /= Apple Touch Icon Sizes =/
// ----------------------------
// https://mathiasbynens.be/notes/touch-icons
# remove_filter('skeleton_apple_icons','skeleton_apple_icon_sizes');
add_filter('skeleton_apple_icons','muscle_apple_icon_sizes');
function muscle_apple_icon_sizes($vsizes) {
// Output your own list of sizes and icon URLs (HTML)
# $vsizes = ''; // etc.
return $vsizes;
}
// /= Apple Startup Images =/
// --------------------------
# remove_filter('skeleton_startup_images','skeleton_apple_startup_images');
add_filter('skeleton_startup_images','muscle_apple_startup_images');
function muscle_apple_startup_images($vimages) {
// Output your own list of startup images (HTML)
# $vimages = ''; // etc.
return $vimages;
}
// /= Custom Browser Detection Styling =/
// --------------------------------------
// Note: These filters are auto-added so there is no need to 'add_filter'
// Any existing relevent theme option values are passed to these filters.
// Works much better with PHP Browser Detection, but is not required.
// https://wordpress.org/plugins/php-browser-detection/
// note: uses browscap.ini http://browscap.org/
# $browser_version = get_browser_version();
# $browser_info = php_browser_info();
// IE (is_ie)
function muscle_custom_styles_ie($vstyles) {
# insert other conditional check here eg.
# if (get_browser_version() < 7) {
# $vstyles .= '#updateyourbrowermessage {display:block;}';
# }
return $vstyles;
}
// Firefox (is_firefox)
function muscle_styles_firefox($vstyles) {
# insert other conditional check here eg.
return $vstyles;
}
// Safari (is_safari)
function muscle_styles_safari($vstyles) {
# insert other conditional check here
return $vstyles;
}
// Chrome (is_chrome)
function muscle_styles_chrome($vstyles) {
# insert other conditional check here
return $vstyles;
}
// Opera (is_opera)
function muscle_styles_opera($vstyles) {
# insert other conditional check here
return $vstyles;
}
// Lynx
function muscle_styles_lynx($vstyles) {
# insert other conditional check here eg.
return $vstyles;
}
// Netscape
function muscle_styles_netscape($vstyles) {
# insert other conditional check here eg.
return $vstyles;
}
// /= Custom Mobile Detection Styling =/
// -------------------------------------
// Note: Dynamic Skin CSS must be on for this to work as added via skin.php
// These mobile detection filters require PHP Browser Detection plugin
// https://wordpress.org/plugins/php-browser-detection/
// Note: These filters are auto-added *when PHP Browser Detection plugin is active*
// ...so there is no need for an add_filter line for these functions.
// Any existing relevent theme option values are passed to these filters.
// Desktop only (is_desktop)
function muscle_styles_desktop($vstyles) {
# insert other conditional check here
return $vstyles;
}
// Mobile only (is_mobile)
function muscle_styles_mobile($vstyles) {
# insert other conditional check here
return $vstyles;
}
// Tablet only (is_tablet)
function muscle_styles_tablet($vstyles) {
# insert other conditional check here
return $vstyles;
}
// Desktop only (is_iphone)
function muscle_styles_iphone($vstyles) {
// insert other conditional check here eg.
# is_phone($version)) {$vstyles .= '';}
return $vstyles;
}
// Ipad only styles (is_ipad)
function muscle_styles_ipad($vstyles) {
// insert other conditional check here eg.
# is_pad($version)) {$vstyles .= '';}
return $vstyles;
}
// Ipod only styles (is_ipod)
function muscle_styles_ipod($vstyles) {
// insert other conditional check here eg.
# eg. is_pod($version)) {$vstyles .= '';}
return $vstyles;
}
// /= Google CDN jQuery Version =/
// -------------------------------
add_filter('skeleton_google_jquery_version','muscle_google_jquery_version');
function muscle_google_jquery_version($vversion) {
// use a different version of jQuery (CAUTION: not a good idea!)
// (matching current WordPress version is used by default)
# $vversion = '1.7.2';
return $vversion;
}
// /=================
// === Thumbnails ===
// =================/
// skeleton_thumbnail_width
// skeleton_thumbnail_height
// skeleton_image_sizes
// skeleton_post_thumbnail_size
// skeleton_list_thumbnail_size
// skeleton_thumbnail_wrapper_classes
// skeleton_thumbnail_classes
// skeleton_thumbnail_override
// /================/
// /= Default Thumbnail Width =/
// -----------------------------
add_filter('skeleton_thumbnail_width','muscle_thumbnail_width');
function muscle_thumbnail_width($vwidth) {
# $vwidth = 200;
return $vwidth;
}
// /= Default Thumbnail Height =/
// ------------------------------
add_filter('skeleton_thumbnail_height','muscle_thumbnail_height');
function muscle_thumbnail_height($vheight) {
# $vheight = 200;
return $vheight;
}
// /= Media Image Sizes =/
// -----------------------
add_filter('skeleton_image_sizes','muscle_image_sizes');
function muscle_image_sizes($vimagesizes) {
// Ref: Default image sizes
// $vimagesizes[0] = array('name' => 'squared150', 'width' => 150, 'height' => 150, 'crop' => true);
// $vimagesizes[1] = array('name' => 'squared250', 'width' => 250, 'height' => 250, 'crop' => true);
// $vimagesizes[2] = array('name' => 'video43', 'width' => 320, 'height' => 240, 'crop' => true);
// $vimagesizes[3] = array('name' => 'video169', 'width' => 320, 'height' => 180, 'crop' => true);
// eg. Add an image size (here 600x600)
# $vimagesizes[] = array('name' => 'squared600', 'width' => 600, 'height' => 600, 'crop' => true);
// eg. Change cropping defaults for an image size
# foreach ($vimagesizes as $vkey => $vimagesize) {
# if ($vimagesize['name'] == 'squared150') {
# $vimagesizes[$vkey]['crop'] = array('top','left');
# }
# }
return $vimagesizes;
}
// /= Post List Thumbnail Size =/
// ------------------------------
add_filter('skeleton_list_thumbnail_size','muscle_list_thumbnail_size');
function muscle_list_thumbnail_size($vsize) {
// eg. Set to 4:3 video size for custom post type of 'video'
# if (is_post_type_archive('video')) {$vsize = 'video43';}
// eg. Set to squared150 for search pages
# if (is_search()) {$vsize = 'squared150';}
return $vsize;
}
// /= Post List Thumbnail Alignment =/
// -----------------------------------
add_filter('skeleton_list_thumbnail_align','muscle_list_thumbnail_align');
function muscle_list_thumbnail_align($valign) {
// change the thumbnail list alignment
# if (is_post_type_archive('video')) {$valign = 'alignright';}
return $valign;
}
// /= Post Thumbnail Size =/
// -------------------------
// note: also used for page featured images
// filter exists at priority 1 for theme options perpost metabox override
add_filter('skeleton_post_thumbnail_size','muscle_post_thumbnail_size',10);
function muscle_post_thumbnail_size($vsize) {
// eg. Set to full size for the 'images' category
# if (is_category('images')) {$vsize = 'full';}
// eg. Set to full size for custom post type of 'image'
# if (get_post_type(get_the_ID()) == 'image') {$vsize = 'full';}
# OR alternatively
# if (is_singular('image')) {$vsize = 'full';}
return $vsize;
}
// /= Post Thumbnail Alignment =/
// ------------------------------
add_filter('skeleton_post_thumbnail_align','muscle_post_thumbnail_align');
function muscle_post_thumbnail_align($valign) {
// change the post thumbnail alignment
# if (get_post_type(get_the_ID()) == 'video')) {$valign = 'alignright';}
return $valign;
}
// /= Thumbnail Wrapper Classes =/
// -------------------------------
add_filter('skeleton_thumbnail_wrapper_classes','muscle_thumbnail_wrapper_classes');
function muscle_thumbnail_wrapper_classes($vclasses) {
// eg. change the default alignment to right for a particular post ID
# if (get_the_ID() == '100') {$vclasses = str_replace('alignleft','alignright',$vclasses);}
return $vclasses;
}
// /= Thumbnail Image Classes =/
// -----------------------------
add_filter('skeleton_thumbnail_classes','muscle_thumbnail_classes');
function muscle_thumbnail_classes($vclasses) {
// eg. add an additional class for all archive type pages
# if (is_archive()) {$vclasses .= ' archive-thumbnail';}
return $vclasses;
}
// /= Thumbnail Override =/
// ------------------------
add_filter('skeleton_thumbnail_override','muscle_thumbnail_override');
function muscle_thumbnail_override($vhtml) {
// completely override the outputted thumbnail HTML
// eg. do not show thumbnails at all on search pages
# if (is_search()) {$vhtml = '';}
// eg. set a different thumbnail size for the first thumbnail
// if on the homepage or frontpage, here medium (300x300)
# if ( (is_home()) || (is_front_page()) ) {
# if (strstr($vhtml,'')) {
# $vhtml = skeleton_get_thumbnail(get_the_ID(),get_post_type(get_the_ID()),'medium');
# }
# }
return $vhtml;
}
// /===============
// === SKELETON ===
// ===============/
// skeleton_html_comments
// skeleton_layout_width
// skeleton_grid_columns
// skeleton_content_grid_columns
// skeleton_container_classes
// skeleton_header_classes
// skeleton_blog_display_name
// skeleton_blog_description
// skeleton_site_title_display
// skeleton_site_title_description
// skeleton_header_logo_url
// skeleton_header_logo_override
// skeleton_logo_resize
// skeleton_header_menu_settings
// skeleton_header_html_extras
// skeleton_navigation_remove
// skeleton_content_classes
// skeleton_content_columns
// skeleton_content_columns_override
// skeleton_content_width
// skeleton_content_padding_width
// skeleton_footer_classes
// skeleton_footer_menu_settings
// skeleton_footer_html_extras
// /==============/
// /= HTML Comment Wrappers (boolean) =/
// -------------------------------------
// 1.8.5: added this filter
add_filter('skeleton_html_comments', 'muscle_html_comments');
function muscle_html_comments($vhtmlcomments) {
// show HTML element comment wrappers on pages only
# if (is_page()) {$vhtmlcomments = 1;}
return $vhtmlcomments;
}
// /= Maximum Layout Width (integer) =/
// ------------------------------------
add_filter('skeleton_layout_width', 'muscle_layout_width');
function muscle_layout_width($vwidth) {
// maximum width to scale up to via media queries
// 1.5.0: original layout width maximums were 960, 1140 or 1200
// but now this can be set to anything in theme options
# $vwidth = 1200;
return $vwidth;
}
// /= Grid Columns Override (integer) =/
// -------------------------------------
// 1.8.5: added override in grid.php
add_filter('skeleton_grid_columns', 'muscle_grid_columns');
function muscle_grid_columns($columns) {
// set different total layout grid columns for a page
// (you would want to filter sidebar and content columns also)
// valid values 12,16,20,24 (word or number)
# $columns = '20';
return $columns;
}
// /= Content Grid Columns Override (integer) =/
// ---------------------------------------------
// 1.9.5: added this option and filter
add_filter('skeleton_content_grid_columns', 'muscle_content_grid_columns');
function muscle_content_grid_columns($columns) {
// set different total content grid columns, eg. for blog page
// valid values 12,16,20,24 (word or number)
# if (is_home()) ($columns = '20';}
return $columns;
}
// /= Wrap Container Div Classes (array) =/
// ----------------------------------------
add_filter('skeleton_container_classes', 'muscle_container_classes');
function muscle_container_classes($classes) {
// default is an array of container classes based on grid
// you can add extra classes, eg.
# if (is_page()) {$classes[] = 'mycontainerclass';}
return $classes;
}
// /= Header Div Classes (array) =/
// --------------------------------
add_filter('skeleton_header_classes', 'muscle_header_classes');
function muscle_header_classes($classes) {
// default is an array of header classes based on grid
// you can add extra classes, eg.
# if (is_page()) {$classes[] = 'myheaderclass';}
return $classes;
}
// /= Blog Title Display Name (string) =/
// --------------------------------------
// 1.8.5: (currently only applies to header blog title output)
add_filter('skeleton_blog_display_name', 'muscle_blog_display_name');
function muscle_blog_display_name($sitename) {
// change the site title display
# eg. recapitalize site title
# $sitename = "Bio Ship";
return $sitename;
}
// /= Blog Description (string) =/
// -------------------------------
// 1.8.5: (currently only applies to header description output)
add_filter('skeleton_blog_description', 'muscle_blog_description');
function muscle_blog_description($description) {
// change the blog description displayed,
# eg. split desciption display up with line breaks
# $description = str_replace(' ', '
', $description);
return $description;
}
// /= Header Site Title Display (boolean) =/
// -----------------------------------------
// 2.1.1: added missing site title display filter example
add_filter('skeleton_site_title_display', 'muscle_site_title_display');
function muscle_site_title_display($display) {
# eg. only display site title in header on front page
# if (!is_front_page()) {$display = false;} else {$display = true;}
return $display;
}
// /= Header Site Description Display (boolean) =/
// -----------------------------------------------
// 2.1.1: added missing site title description filter example
add_filter('skeleton_site_description_display', 'muscle_site_description_display');
function muscle_site_description_display($display) {
# eg. do not display site description in header on blog page
# if (is_home()) {$display = false;} else {$display = true;}
return $display;
}
// /= Header Logo URL (url) =/
// ---------------------------
add_filter('skeleton_header_logo_url', 'muscle_header_logo_url');
function muscle_header_logo_url($url) {
// to override the logo URL on a per page basis
# eg. change the logo URL for the front page or home page
# if (is_front_page()) {$url = site_url().'/images/frontpage-logo.png';}
# if (is_home()) {$url = site_url().'/images/blogpage-logo.png';}
return $url;
}
// /= Header Logo Override (html) =/
// ---------------------------------
add_filter('skeleton_header_logo_override', 'muscle_header_logo_override');
function muscle_header_logo_override($html) {
// override the entire HTML logo area output
# if (is_front_page()) {$html = my_custom_header_html_function();}
return $html;
}
// /= Header Logo Resize (boolean) =/
// ----------------------------------
add_filter('skeleton_logo_resize', 'muscle_logo_resize_override');
function muscle_logo_resize_override($resize) {
// You could turn logo resize on/off for specific page eg.
# if (is_front_page()) {$resize = 0;}
return $resize;
}
// /= Header Menu Settings (array) =/
// ----------------------------------
add_filter('skeleton_header_menu_settings', 'muscle_header_menu_settings');
function muscle_header_menu_settings($args) {
// change the settings for the header menu display
# eg. change the menu container ID
# $args['container_id'] = 'header_menu';
return $args;
}
// /= Header Extras Output Override (html) =/
// ------------------------------------------
add_filter('skeleton_header_extras', 'muscle_header_extras');
function muscle_header_extras($html) {
// You can set header extra text here as HTML, eg.
# $extras = '