This time I will share jQuery Plugin and tutorial about Customizable jQuery Plugin To Tweet Highlighted Text – quoteShare.js, hope it will help you in programming stack.
quotesShare.js is a tiny and customizable jQuery twitter share plugin which converts used selected text into tweetable quotes with a twitter share button.
How to use it:
1. Add references to jQuery library and the jQuery quotesShare plugin’s script.
1 |
< script src = "jquery.min.js" ></ script > |
2 |
< script src = "js/quoteShare.min.js" ></ script > |
2. In this example we’re going to use Font Awesome 4 for Twitter icon. You can use any other icon set or icon font to display custom share icon in the Twitter share button.
1 |
< link rel = "stylesheet" href = "font-awesome.min.css" > |
3. Just call the function on the target text container and you’re done.
1 |
$( 'article' ).quoteShare(); |
4. Customize the plugin.
01 |
$( 'article' ).quoteShare({ |
03 |
background : '#55acee' , |
07 |
twitterColor : '#ffffff' , |
08 |
twitterElipses : true , |
Change log:
2016-05-12
2016-05-05
v2 (2016-05-01)
- JS & CSS update
- fixed for firefox.
This awesome jQuery plugin is developed by HarryStevens. For more Advanced Usages, please check the demo page or visit the official website.