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
[gravityform id="1" name="Contact Form" title="false" description="false" ajax="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
[gravityform id="1" name="Contact Form" title="false" description="false" ajax="true" tabindex="100"] |
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 | |
function featured_image_in_feed( $content ) { | |
global $post; | |
if( is_feed() ) { | |
if( has_post_thumbnail( $post->ID ) ){ | |
$output = get_the_post_thumbnail( $post->ID, 'large', array( 'style' => 'float:right; margin: 10px;' ) ); | |
$content = $output . $content; | |
} | |
if( has_post_format( 'gallery' ) ) { |
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 | |
if( get_post_meta( get_the_ID(), 'diww_sponsored', true ) == 'sponsored' ) { | |
// DO SOMETHING HERE IF 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
<?php | |
if( get_post_meta( get_the_ID(), 'diww_sponsored_type', true ) == 'giveaway' ) { | |
// DO THIS IF GIVEAWAY | |
} |
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 | |
if( get_post_meta( get_the_ID(), 'diww_sponsored', true ) == 'sponsored' ) { | |
if( get_post_meta( get_the_ID(), 'diww_sponsored_type', true ) == 'giveaway' ) { | |
$sponsored_content = '<p class="sponsored">This is a sponsored giveaway.</p>'; | |
$sponsored_content .= $content; | |
return $sponsored_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
<?php | |
if( get_post_meta( get_the_ID(), 'diww_sponsored', true ) == 'sponsored' ) { | |
if( get_post_meta( get_the_ID(), 'diww_sponsored_type', true ) == 'giveaway' ) { | |
$sponsored_content = '<p class="sponsored">This is a sponsored giveaway.</p>'; | |
$sponsored_content .= $content; | |
return $sponsored_content; | |
} | |
if( get_post_meta( get_the_ID(), 'diww_sponsored_type', true ) == 'review' ) { | |
$sponsored_content = '<p class="sponsored">This is a sponsored review.</p>'; |
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 | |
function diww_show_sponsor($content) { | |
if( get_post_meta( get_the_ID(), 'diww_sponsored', true ) == 'sponsored' ) { | |
if( get_post_meta( get_the_ID(), 'diww_sponsored_type', true ) == 'giveaway' ) { | |
$sponsored_content = '<p class="sponsored">This is a sponsored giveaway.</p>'; | |
$sponsored_content .= $content; | |
return $sponsored_content; | |
} | |
if( get_post_meta( get_the_ID(), 'diww_sponsored_type', true ) == 'review' ) { |
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 | |
function diww_pre_content($content) { | |
$pre_content = '<p class="sponsored">This is sponsored content.</p>'; | |
$pre_content .= $content; | |
return $pre_content; | |
} | |
add_filter( 'the_content', 'diww_pre_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
<?php | |
// DISPLAY USER'S FIRST NAME | |
function user_first_name() { | |
global $current_user; | |
get_currentuserinfo(); | |
$first_name = esc_attr( $current_user->user_firstname ); | |
return $first_name; | |
} |