This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_action( 'admin_menu', function() { | |
| remove_meta_box( 'dashboard_primary', 'dashboard', 'core' ); | |
| } ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if (navigator.userAgent.match(/Mobi/)) document.documentElement.className += " is-mobile"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function my_async_scripts( $tag, $handle, $src ) { | |
| switch ( $handle ) { | |
| case 'picturefill': | |
| case 'wp-embed': | |
| $tag = str_replace( ' src=', ' async defer src=', $tag ); | |
| break; | |
| } | |
| return $tag; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "type" : "project", | |
| "minimum-stability": "dev", | |
| "prefer-stable": true, | |
| "config": { | |
| "secure-http": false | |
| }, | |
| "repositories" : [ | |
| { | |
| "type" :"composer", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| remove_action( 'wp_head', 'print_emoji_detection_script', 7 ); | |
| remove_action( 'admin_print_scripts', 'print_emoji_detection_script' ); | |
| remove_action( 'wp_print_styles', 'print_emoji_styles' ); | |
| remove_action( 'admin_print_styles', 'print_emoji_styles' ); | |
| remove_filter( 'the_content_feed', 'wp_staticize_emoji' ); | |
| remove_filter( 'comment_text_rss', 'wp_staticize_emoji' ); | |
| remove_filter( 'wp_mail', 'wp_staticize_emoji_for_email' ); | |
| add_filter( 'tiny_mce_plugins', function( $plugins ) { | |
| if ( is_array( $plugins ) ) { | |
| return array_diff( $plugins, array( 'wpemoji' ) ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| function my_admin_menus() { | |
| if ( ! current_user_can( 'remove_users' ) ) { // See: https://codex.wordpress.org/Roles_and_Capabilities | |
| // remove_menu_page( 'index.php' ); // Dashboard | |
| // remove_menu_page( 'edit.php' ); // Posts | |
| // remove_menu_page( 'upload.php' ); // Media | |
| // remove_menu_page( 'edit.php?post_type=page' ); // Pages | |
| // remove_menu_page( 'edit-comments.php' ); // Comments | |
| // remove_menu_page( 'themes.php' ); // Appearance | |
| // remove_menu_page( 'plugins.php' ); // Plugins |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| function my_body_class( $classes ) { | |
| if ( wp_is_mobile() ) { | |
| $classes[] = 'is-mobile'; | |
| } | |
| return $classes; | |
| } | |
| add_filter( 'body_class', 'my_body_class' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| function my_http_api_curl( $handle ) { | |
| curl_setopt( $handle, CURLOPT_CONNECTTIMEOUT, 180 ); | |
| curl_setopt( $handle, CURLOPT_TIMEOUT, 180 ); | |
| } | |
| add_action( 'http_api_curl', 'my_http_api_curl', 100, 1 ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'auto_update_plugin', '__return_false' ); | |
| add_filter( 'auto_update_theme', '__return_false' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| function my_unregister_taxonomies() | |
| { | |
| unregister_taxonomy_for_object_type( 'category', 'post' ); | |
| unregister_taxonomy_for_object_type( 'category', 'pages' ); | |
| unregister_taxonomy_for_object_type( 'post_tag', 'pages' ); | |
| } | |
| add_action( 'init', 'my_unregister_taxonomies' ); |