[英]How to set image thumbnail when sharing the whole site?
I have shared the site in messenger and noticed that there is no featured image in the generated box. 我在Messenger中共享了该网站,并注意到在生成的框中没有特色图片。 I know that if i want to share posts i can use WordPress functions like
我知道,如果我想分享帖子,我可以使用WordPress之类的功能
the_post_thumbnail()
the_post_thumbnail()
etc.. But what if i share the whole site ? 等等。但是如果我共享整个网站怎么办? ps i didn't found anything on Google about sharing the whole site.
附言:我没有在Google上找到有关共享整个网站的任何信息。 I think something like this could help:
我认为这样可以帮助:
if ( has_post_thumbnail() ) {
the_post_thumbnail();
}
the_content();
Any help would be appreciated 任何帮助,将不胜感激
you can use SEO yoast plugin and set OG image, description for each post, page etc.. 您可以使用SEO yoast插件并设置OG图片,每个帖子的描述,页面等。
https://wordpress.org/plugins/wordpress-seo/ https://wordpress.org/plugins/wordpress-seo/
https://kb.yoast.com/kb/getting-open-graph-for-your-articles/ https://kb.yoast.com/kb/getting-open-graph-for-your-articles/
https://www.elegantthemes.com/blog/tips-tricks/how-to-add-open-graph-tags-to-wordpress https://www.elegantthemes.com/blog/tips-tricks/how-to-add-open-graph-tags-to-wordpress
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.