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
| wp_redirect(get_permalink($post->post_parent)); |
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
| add_filter( 'widget_text', array( $wp_embed, 'run_shortcode' ), 8 ); | |
| add_filter( 'widget_text', array( $wp_embed, 'autoembed'), 8 ); |
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
| /** | |
| * A simple menu with a :hover action | |
| */ | |
| html { | |
| background: #f06; | |
| background: linear-gradient(45deg, #f06, yellow); | |
| min-height: 100%; | |
| font: 100%/2.5 helvetica, arial; | |
| } |
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 wpbeginner_restrict_editing( $allcaps, $cap, $args ) { | |
| // Bail out if we're not asking to edit or delete a post ... | |
| if( 'edit_post' != $args[0] && 'delete_post' != $args[0] | |
| // ... or user is admin | |
| || !empty( $allcaps['manage_options'] ) | |
| // ... or user already cannot edit the post | |
| || empty( $allcaps['edit_posts'] ) ) | |
| return $allcaps; |
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
| add_action('template_redirect', 'redirect_single_post'); | |
| function redirect_single_post() { | |
| if (is_search()) { | |
| global $wp_query; | |
| if ($wp_query->post_count == 1) { | |
| wp_redirect( get_permalink( $wp_query->posts['0']->ID ) ); | |
| } | |
| } | |
| } |
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
| // Enables the Link Manager that existed in WordPress until version 3.5 | |
| add_filter( 'pre_option_link_manager_enabled', '__return_true' ); |
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
| ; This is a settings export file for the WordPress SEO plugin by Yoast.com - http://yoast.com/wordpress/seo/ | |
| [wpseo] | |
| ignore_blog_public_warning = | |
| ignore_tour = "ignore" | |
| ignore_page_comments = | |
| ignore_permalink = | |
| ms_defaults_set = | |
| version = "1.4.1" | |
| tracking_popup = "done" |
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
| # Redirect Empty Searches to root | |
| RewriteCond %{QUERY_STRING} ^s=$ | |
| RewriteRule ^ /? [L,R=301] |
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
| global $user_login; | |
| get_currentuserinfo(); | |
| if (!current_user_can('update_plugins')) { /* checks to see if current user can update plugins */ | |
| add_action( 'init', create_function( '$a', "remove_action( 'init', 'wp_version_check' );" ), 2 ); | |
| add_filter( 'pre_option_update_core', create_function( '$a', "return null;" ) ); | |
| } |
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
| // Add custom fields to user profiles | |
| function vuurr_sm_contactmethods( $contactmethods ) { | |
| // Add | |
| $contactmethods['twitter'] = 'Twitter'; | |
| $contactmethods['facebook'] = 'Facebook'; | |
| $contactmethods['googleplus'] = 'Google+ About'; | |
| // Remove | |
| unset($contactmethods['yim']); | |
| unset($contactmethods['aim']); | |
| unset($contactmethods['jabber']); |