Simple Popup Social Media Sharing Plugin with jQuery
| File Size: | 5.72KB |
|---|---|
| Views Total: | 4222 |
| Last Update: | |
| Publish Date: | |
| Official Website: | Go to website |
| License: | MIT |
A very simple jQuery social plugin that allows you to create social media sharing dialogs (facebook, twitter, google plus, etc ) in a popup window.
You might also like:
How to use it:
1. Include jQuery Library and jquery.socialSharers.js on your web page
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script> <script src="jquery.socialSharers.js"></script>
2. Markup
<ul class="sharers"> <li><a data-share="facebook" data-title="Check this, yo" data-link="https://www.jqueryscript.net" data-description="Nice, very nice" href="https://www.facebook.com/sharer/sharer.php?u=gizoogle.net" target="_blank">Oh hai Facebook</a></li> <li><a data-share="twitter" data-title="Check this, yo" data-link="https://www.jqueryscript.net" data-hashtags="cowabunga,gnarly" href="https://www.twitter.com/share?url=http://www.gizoogle.net/" target="_blank">Oh hai Twitter</a></li> <li><a data-share="googleplus" data-title="Check this, yo" data-link="https://www.jqueryscript.net" href="https://plus.google.com/share?url=http://www.gizoogle.net/" target="_blank">Oh hai Google Plus</a></li> </ul>
3. Call the plugin
<script>
$(function() {
$('.sharers').socialSharers({
twitter: {
handle: 'YOUR TWITTER NAME' // will add 'via @neilcarpenter' on tweets
},
facebook: {
appID: 'YOUR APP ID HERE' // will load FB SDK asynchronously and add 'via [FB APP NAME]'
},
googleplus: {
// no options yet
}
});
});
</script>
This awesome jQuery plugin is developed by unknown. For more Advanced Usages, please check the demo page or visit the official website.











