我在这个页面的点赞按钮www.vivopositivo.it/media/foto/guarda-chi-sorride-over-18-e-famiglie/上遇到了一个奇怪的问题。我正在使用PrettyPhoto来包含来自Flickr的图片,并在lightbox中打开它们。每张图片都有自己的like按钮,该按钮显示在lightbox中,并使用特定的URL,例如:
http://www.vivopositivo.it/media/foto/guarda-chi-sorride-over-18-e-famiglie/#prettyPhoto[pp_gal]/1/
其中,#prettyPhotopp_gal1/1/中的数字是特定图像的密钥。
like按钮包含在以下代码中:
iframe src="//www.facebook.com/plugins/like.php?locale=en_US&href={location_href}&layout=button_count&show_faces=true&width=500&action=like&font&colorscheme=light&height=23“scrolling="no”frameborder="0“style=”边框:无;溢出:隐藏;宽度:500px;高度:23px;“allowTransparency="true”/iframe
其中{location_href}将替换为图像特定的URL。
这对大多数图像都有效,但对其中一些图像无效!他们似乎得到了页面的点赞计数器,因此,我得到了大约10张图片,显示了相同的128个点赞计数器,这显然是错误的。这看起来完全是随机的..
你有什么办法解决这个问题吗?
干杯,安德里亚
发布于 2012-05-14 20:02:24
这是因为URL中的#标识了图像。
有关详细说明,请参阅this post。
https://stackoverflow.com/questions/10581167
复制相似问题