This file contains 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 fb_filter_query( $query, $error = true ) { | |
if ( is_search() ) { | |
$query->is_search = false; | |
$query->query_vars[s] = false; | |
$query->query[s] = false; | |
// to error | |
if ( $error == true ) | |
$query->is_404 = true; |
This file contains 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
=== Plugin Name === | |
Contributors: (this should be a list of wordpress.org userid's) | |
Donate link: https://example.com/ | |
Tags: tag1, tag2 | |
Requires at least: 4.7 | |
Tested up to: 5.4 | |
Stable tag: 4.3 | |
Requires PHP: 7.0 | |
License: GPLv2 or later | |
License URI: https://www.gnu.org/licenses/gpl-2.0.html |
This file contains 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 href="http://www.alexa.com/siteinfo/wpism.com"><script type="text/javascript" src="http://xslt.alexa.com/site_stats/js/t/a?url=wpism.com"></script></a> |
This file contains 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( 'the_content', 'featured_image_in_feed' ); | |
function featured_image_in_feed( $content ) { | |
global $post; | |
if( is_feed() ) { | |
if ( has_post_thumbnail( $post->ID ) ){ | |
$output = get_the_post_thumbnail( $post->ID, 'medium', array( 'style' => 'float:right; margin:0 0 10px 10px;' ) ); | |
$content = $output . $content; | |
} | |
} |
This file contains 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
/* Code to Display Featured Image on top of the post */ | |
add_action( 'genesis_before_entry', 'featured_post_image', 8 ); | |
function featured_post_image() { | |
if ( ! is_singular( 'post' ) ) return; | |
the_post_thumbnail('post-image'); | |
} |
This file contains 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 Google Tag Manager script on Genesis Framework | |
**/ | |
add_action('genesis_before', 'google_tag_manager'); | |
function google_tag_manager() { ?> | |
<!-- Google Tag Manager --> | |
ADD YOUR GOOGLE TAG MANAGER CODE HERE | |
<!-- End Google Tag Manager --> | |
<?php |
This file contains 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 featuredtoRSS($content) { | |
global $post; | |
if ( has_post_thumbnail( $post->ID ) ){ | |
$content = '<a href=" . get_permalink() . " rel="nofollow ugc">' . get_the_post_thumbnail( $post->ID, $imgsize, array( 'style' => 'float:left; margin:0 15px 15px 0;' ) ) . '</a>' . $content; | |
} | |
return $content; | |
} | |
add_filter('the_excerpt_rss', 'featuredtoRSS'); | |
add_filter('the_content_feed', 'featuredtoRSS'); |
This file contains 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
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteCond %{HTTP_HOST} ^olddomain\.com$ [OR] | |
RewriteCond %{HTTP_HOST} ^www\.olddomain\.com$ | |
RewriteRule (.*)$ http://www.newdomain.com/$1 [R=301,L] | |
</IfModule> |
NewerOlder