Adding items to tag in php
-
I am using elegant themes, not sure if that helps.
And I am manually adding schema itemprop to my php files. I am able to get the majority of it solved like post-meta needed date published in functions.phpif ( $postinfo ) : echo '<p class="post-meta" itemprop="datePublished">'; echo et_pb_postinfo_meta( $postinfo, et_get_option( 'divi_date_format', 'M j, Y' ), esc_html__( '0 comments', 'Divi' ), esc_html__( '1 comment', 'Divi' ), '% ' . esc_html__( 'comments', 'Divi' ) ); echo '</p>'; endif;
but I am having trouble with: when php generates the html
<img>
tag for thumbnails (if it even does that)
I think I’ve looked for all the typical things in all the files: things like
$thumb
or
the_post_thumbnail()
Please let me know if anyone can help.
I’m looking to achieve that img has itemprop=”image” and looks like this across all blog posts:
<img src="https://.jpg" alt="alt" width="1080" height="675" itemprop="image">
Thank you. I’m not so savvy so I appreciate your help.
- The topic ‘Adding items to tag in php’ is closed to new replies.