Corrections:
add_filter( ‘amp_post_template_metadata’, ‘xyz_amp_modify_json_metadata’, 10, 2 );
function xyz_amp_modify_json_metadata($metadata, $post) {
$arr = get_post_custom_values(‘_schema’);
$metadata = unserialize($arr[0]);
return $metadata;
}
Mod. wordpress\wp-content\plugins\wp-structuring-markup\includes\wp-structuring-display.php
line 173: global $post;
line 174: update_post_meta($post->ID, “_schema”, $args);
-
This reply was modified 7 years, 7 months ago by gucoriw.