// Disable the emoji's Scripts from WordPress Head
remove_action( 'wp_head', 'print_emoji_detection_script', 7 );
remove_action( 'wp_print_styles', 'print_emoji_styles' );
wordpress
All about wordpress related tips and tricks, codes, snippets etc.
-
-
Add the following code inside theme functions.php
// Remove emoji script from WordPress Header remove_action( 'wp_head', 'print_emoji_detection_script', 7 ); remove_action( 'wp_print_styles', 'print_emoji_styles' );
-
Replace the following /wp-content/themes/genesis/lib/functions/seo.php
function genesis_detect_seo_plugins() { return genesis_detect_plugin( // Use this filter to adjust plugin tests. apply_filters( 'genesis_detect_seo_plugins', // Add to this array to add new plugin checks. [ // Classes to detect. 'classes' => [ 'All_in_One_SEO_Pack', 'All_in_One_SEO_Pack_p', 'HeadSpace_Plugin', 'Platinum_SEO_Pack', 'wpSEO', 'SEO_Ultimate', ], // Functions to detect. 'functions' => [], // Constants to detect. 'constants' => [ 'WPSEO_VERSION', 'SEOPRESS_VERSION' ], ] ) ); }
Replace with:-
function genesis_detect_seo_plugins() { return true; }
-
Add the following code inside functions.php
add_filter( 'show_admin_bar', '__return_false' );
The above code will hide admin bar for all users including administrators. If you like show admin bar to admins only, then add the following code:-
add_action('after_setup_theme', 'remove_admin_bar'); function remove_admin_bar() { if (!current_user_can('administrator') && !is_admin()) { show_admin_bar(false); } }
-
Add this into functions.php
genesis_register_sidebar( array( 'id' => 'custom-widget', 'name' => __( 'Custom Widget', 'wbxpress' ), 'description' => __( 'Custom Widget Area', 'wbxpress' ), ) ); add_action( 'genesis_after_header', 'add_genesis_widget_area' ); function add_genesis_widget_area() { genesis_widget_area( 'custom-widget', array( 'before' => '<div class="custom-widget widget-area">', 'after' => '</div>', ) ); }
Then add this into styles.php
.custom-widget { background-color: #fff; padding: 30px 20px; margin: 30px auto 0; } @media only screen and (min-width: 960px) { .custom-widget { max-width: 1080px; } .custom-widget .widget { float: left; padding: 0 20px; width: 25%; } }
The above style is for 4 columns widget area. You can change the width to customize according to your requirement. for example width: 50%; for 2 column layout.
-
Old permalink: https://wbxpress.net/2011/03/a-long-post-url.html
New permalink: https://wbxpress.net/a-long-post-url/
Add the following into the virtual host configuration file.
rewrite "/([0-9]{4})/([0-9]{2})/(.*).html" https://wbxpress.net/$3 permanent;