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 | |
// Can be used in any (template) file, will do the same as [wpseo_map] in posts/pages. | |
if( function_exists( 'wpseo_local_show_map' ) ) { | |
$params = array( | |
'echo' => true, | |
'id' => 347, | |
'width' => 800, | |
'height' => 600, | |
'zoom' => 5, | |
'show_route' => 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 | |
// // Can be used in any (template) file, will do the same as shortcode [wpseo_address] | |
if( function_exists( 'wpseo_local_show_address' ) ) { | |
$params = array( | |
'echo' => true, | |
'id' => 237, | |
'show_state' => true, | |
'show_country' => true, | |
'show_phone' => true, | |
'oneline' => false, |
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 | |
// Can be used in any (template) file, will do the same as [wpseo_opening_hours] | |
if ( function_exists( 'wpseo_local_show_opening_hours' ) ) { | |
$params = array( | |
'id' => 237, | |
'hide_closed' => false, | |
'echo' => true, | |
'comment' => '' | |
); | |
wpseo_local_show_opening_hours( $params ); |
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 | |
/** | |
* Register widget areas for Genesis Childthemes | |
* Includes i18n for name and description. | |
*/ | |
genesis_register_sidebar( array( | |
'id' => 'Widgetarea_slug', | |
'name' => __( 'Title of your widgetarea', 'example' ), | |
'description' => __( 'Description that is shown in the admin of your WordPress website', 'example' ), | |
) ); |
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 (custom field) content to the post's content before WP SEO Analysis. | |
* | |
* @param string $content The content of a posts content-field. | |
* | |
* @return string The original content plus the value of the postmeta with meta_key '_yoast_postmeta_example'. | |
*/ | |
function yst_custom_content_analysis( $content ) { | |
global $post; |
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
Movie on 'http://www.skyriderfilms.com/gay-video-series-coffee-talk-trailer-released/' returns: | |
stdClass Object | |
( | |
[version] => 1.0 | |
[type] => video | |
[html] => <div id="wistia_4fpms58ph5" class="wistia_embed" style="width:960px;height:568px;"><div itemprop="video" itemscope itemtype="http://schema.org/VideoObject"><meta itemprop="name" content="Coffee Talk Trailer" /><meta itemprop="duration" content="PT30S" /><meta itemprop="thumbnailUrl" content="http://embed-0.wistia.com/deliveries/0ab49f12e1f1bc4000c9b784832500c6e1f1e809.bin" /><meta itemprop="contentURL" content="http://embed-0.wistia.com/deliveries/9666db8494fd669aa8e6016985768454549f20cc.bin" /><meta itemprop="embedURL" content="http://embed-0.wistia.com/flash/embed_player_v2.0.swf?2013-10-04&autoPlay=false&banner=true&controlsVisibleOnLoad=true&customColor=333333&endVideoBehavior=default&fullscreenDisabled=true&hdUrl%5Bext%5D=flv&hdUrl%5Bheight%5D=720&hdUrl%5Bsize%5D=9910795&hdUrl%5Btype%5D=hdflv&hdUrl%5Burl%5D=http%3A%2F%2Fembed-0.wistia.co |
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 | |
/** | |
* Prevent addition of prev/next rel link by WordPress SEO | |
* | |
* @return string Returns empty string | |
*/ | |
function tv_remove_prevnext_links () { | |
/* If you want to remove the prev/next links from specific pages, | |
this would be the place to add some filter. |
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
# BEGIN WordPress | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteBase / | |
RewriteRule ^index\.php$ - [L] | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteCond %{REQUEST_FILENAME} !-d | |
RewriteRule . /index.php [L] | |
</IfModule> | |
# END WordPress |
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
ystThemeConfigL10n = { choose_image: "Use Image"}; | |
// Taken and adapted from http://www.webmaster-source.com/2013/02/06/using-the-wordpress-3-5-media-uploader-in-your-plugin-or-theme/ | |
jQuery(document).ready(function ($) { | |
var yst_custom_uploader; | |
var yst_target_id; | |
$('.yst_image_upload_button').click(function (e) { | |
yst_target_id = e.currentTarget.id.replace(/_button$/, '_input'); | |
e.preventDefault(); | |
if (yst_custom_uploader) { |
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 | |
// do not copy the line above | |
/** | |
* Removes the twittercard-information from Jetpack | |
* Thus allows WordPress SEO to handle the twittercards | |
*/ | |
function yst_remove_twittercard_info() { | |
remove_filter( 'jetpack_open_graph_tags', 'wpcom_twitter_cards_tags' ); | |
remove_filter( 'jetpack_open_graph_tags', 'change_twitter_site_param' ); |
OlderNewer