jetpack icon indicating copy to clipboard operation
jetpack copied to clipboard

Sharing: Gracefully handle multiple instances per post

Open kraftbj opened this issue 12 years ago • 3 comments

By default, sharing_display() should only appear once per post, though users may want to insert multiple instances (before and after content, for example).

Since the sharing counts are inserted based on the element's ID, jQuery will only insert the count to the first instance of the sharing buttons.

Instead of using ID, we could use a class instead and insert it into all instances of a particular post's sharing buttons.

https://github.com/Automattic/jetpack/blob/master/modules/sharedaddy/sharing.js#L34 https://github.com/Automattic/jetpack/blob/master/modules/sharedaddy/sharing-sources.php#L80 (I think)

cc: @david-binda

kraftbj avatar Oct 29 '14 22:10 kraftbj

@zinigor do any of your PR solve this issue? I am a bit confused what is going on here.

enejb avatar Dec 11 '14 22:12 enejb

@enejb Yes, #1374 fixes it.

zinigor avatar Dec 12 '14 13:12 zinigor

Fixed in #1374

zinigor avatar Dec 12 '14 20:12 zinigor