共享按钮共享主页而不是实际页面

共享按钮共享主页而不是实际页面

本文介绍了共享按钮共享主页而不是实际页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于客户的博客,我在每个博客页面的底部添加了社交共享按钮: http://www.pano-solutions .be/5-tips-voor-een-great-place-to-work.php

For a client's blog I added social share buttons at the bottom each blogpage:http://www.pano-solutions.be/5-tips-voor-een-great-place-to-work.php

我为此使用sharethis插件.但是,当我单击任何共享按钮时,它将共享网站的主页而不是博客页面.不是很有用.我在sharethis上搜索了FAQ,但是没有找到任何有用的帮助.

I use the sharethis plugin for this. However, when I click on any of the sharebuttons, It will share the mainpage of the website instead of the blogpage. Not very usefull. I searched the FAQ on sharethis, but didn't find any usefull help there.

有人知道我该如何解决这个问题,或者知道任何可行的替代方法或良好实践,以了解如何自己做到这一点?

Someone knows how I can fix this or know any working alternatives or good practises on how to do this myself?

推荐答案

Share这有一个调整,您可以在其中添加:expr:st_title='data:post.title' expr:st_url='data:post.url'到每个按钮,强制共享按钮共享帖子中的链接,而不是共享链接.浏览器.

ShareThis has a tweak where you can add: expr:st_title='data:post.title' expr:st_url='data:post.url' to each button, forcing the share buttons to share the link in the post instead of the link in the broswer.

代码看起来类似于以下内容:

The code would look something similar to this:

    < span class='st_twitter_hcount' expr:st_title='data:post.title' expr:st_url='data:post.url'/>
< span class='st_facebook_hcount' expr:st_title='data:post.title' expr:st_url='data:post.url'/>
< span class='st_googleplus_hcount' expr:st_title='data:post.title' expr:st_url='data:post.url'/>
< span class='st_linkedin_hcount' expr:st_title='data:post.title' expr:st_url='data:post.url'/>

这篇关于共享按钮共享主页而不是实际页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-18 20:57