如果我的网站导航依赖于URL中的哈希标签,我可以使用ShareThis/AddThis按钮吗? [英] Can I use a ShareThis/AddThis Button if my site's navigation relies on Hash tags in the url?
问题描述
我想在我的网站上嵌入一个ShareThis/AddThis按钮,但是网站的导航依赖于URL中的Hash标签.每个页面都分配有唯一的哈希值(即 http://domain.com/index.php#products ).不能更改导航/页面设计.这些服务是否会保留哈希值(均在页面上嵌入JS)?如果没有,有什么替代解决方案?
I want to embed a ShareThis/AddThis button on my site but the site's navigation relies on Hash tags in the url. Each page is assigned a unique hash value (ie, http://domain.com/index.php#products). Changing the navigation/page design isn't an option. Will these service preserve the hash value (both embed JS on the page)? If they don't, what are some alternative solutions?
推荐答案
只需将#替换为%23(#的URL编码版本),就可以了. ;)我喜欢使用addthis的远程"版本:http://www.addthis.com/bookmark.php?url=your_url_here%23hash_tag_here
Just replace the # with %23 (the URL encoded version of #) and you'll be fine. ;) I like to use the "remote" version of addthis : http://www.addthis.com/bookmark.php?url=your_url_here%23hash_tag_here
这篇关于如果我的网站导航依赖于URL中的哈希标签,我可以使用ShareThis/AddThis按钮吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!