Created
July 8, 2016 12:03
-
-
Save danielpowney/565d21c0f133a2e4124ab11fa2be4109 to your computer and use it in GitHub Desktop.
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
<?php | |
/** | |
* Adds itemprop=aggregateRating | |
* | |
* @param unknown $microdata | |
* @param unknown $post_id | |
* @return string | |
*/ | |
function mrp_microdata_aggregate_rating_attributes( $microdata, $post_id ) { | |
return 'itemprop="aggregateRating" itemscope itemtype="http://schema.org/AggregateRating"'; | |
} | |
add_filter( 'mrp_microdata_aggregate_rating_attributes', 'mrp_microdata_aggregate_rating_attributes', 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment