Generating Custom Twitter Share Links with jQuery - Tweetable

File Size: 3.31 KB
Views Total: 1267
Last Update:
Publish Date:
Official Website: Go to website
License: MIT
Generating Custom Twitter Share Links with jQuery - Tweetable

Tweetable is an extremely lightweight jQuery plugin that helps you generate a tweet link to share your custom text on Twitter.

How to use it:

1. Include jQuery library and the jQuery tweetable plugin on your web page.

<script src="jquery.min.js"></script>
<script src="tweetable.js"></script>

2. Wrap the text you want to share into a tweet link as displayed follow. data-user attribute is used to set your own Twitter account.

<a class="tweetable" data-user="jqueryscript" href="#">I'm a tweetable link!</a>

3. You can also specify custom message to share on Twitter using data-message attribute.

<a class="tweetable" data-user="jqueryscript" data-message="Custom message" href="#">Share On Twitter!</a>

This awesome jQuery plugin is developed by omarish. For more Advanced Usages, please check the demo page or visit the official website.