Download Demo
tweetParser.js Parse elements containing a tweets and turn URLS, @users & #hashtags into working urls.
1. INCLUDE JS FILES
<script src= "js/jquery.min.js" ></script>
<script src= "js/jquery.tweetParser.min.js" ></script>
|
2. HTML
3. JAVASCRIPT
$( "p.tweets" ).tweetParser();
$( "p.tweets" ).tweetParser({
urlClass : "tweet_link" ,
userClass : "tweet_user" ,
hashtagClass : "hashtag" ,
target : "_blank"
});
|
4. OPTIONS
Parameters |
Type |
default |
description |
urlClass |
String |
tweet_link |
css Class used for url in the tweet |
userClass |
String |
tweet_user |
css Class used for @user profil url in the tweet |
hashtagClass |
String |
hashtag |
css Class used for hashtags url in the tweet |
target |
HTML attribute for anchor tags |
_blank |
target used for all generated |
No comments:
Post a Comment