Last active
July 2, 2025 16:18
-
-
Save jdevalk/5459982 to your computer and use it in GitHub Desktop.
Revisions
-
Joost de Valk revised this gist
Apr 3, 2014 . 2 changed files with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes.File renamed without changes. -
Joost de Valk revised this gist
Apr 3, 2014 . 2 changed files with 11 additions and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,8 +1,9 @@ <?php function fix_content_input( $content, $vid ) { $post = get_post( $vid['post_id'] ); if ( !empty( $post->post_excerpt ) ) { $content = "\n" . 'http://youtube.com/v/'. $post->post_excerpt . "\n" . $content; } return $content; } add_filter( 'wpseo_video_index_content', 'fix_content_input', 10, 2 ); 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,9 @@ <?php function fix_content_input( $content, $vid ) { $post_meta = get_post_meta( $vid['post_id'], 'youtube', true ); if ( !empty( $post_meta ) ) { $content = "\n" . 'http://youtube.com/v/'. $post_meta . "\n" . $content; } return $content; } add_filter( 'wpseo_video_index_content', 'fix_content_input', 10, 2 ); -
Joost de Valk renamed this gist
Apr 25, 2013 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
Joost de Valk created this gist
Apr 25, 2013 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,8 @@ <?php function fix_content_input( $content, $vid ) { $post = get_post( $vid['post_id'] ); if ( !empty( $post->post_excerpt ) ) $content = "\n" . 'http://youtube.com/v/'. $post->post_excerpt . "\n" . $content; return $content; } add_filter( 'wpseo_video_index_content', 'fix_content_input', 10, 2 );