WordPress.org

Plugin Directory

Changeset 427446


Ignore:
Timestamp:
08/23/11 06:06:59 (3 years ago)
Author:
kirilln
Message:
  • Bug fix: made "view more" link appear again (thanks to Somino for reporting via GetSatisfaction)
  • Improvement: both PHP tag and form embed now support view more text config option - see Installation tab (thanks to jenkins2541 for requesting via GetSatisfaction)
  • Improvement: faster page loads because JavaScript now loads in the footer (thanks to Alexander P for suggesting via GetSatisfaction)
  • Improvement: main.js is now minifiable (thanks to Martin E for requesting the fix via GetSatisfaction)
Location:
tweet-blender/trunk
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • tweet-blender/trunk/js/main.js

    r413340 r427446  
    33 */ 
    44 
    5 var TB_version = '3.3.14',  // Plugin version  
     5var TB_version = '3.3.15',  // Plugin version  
    66TB_rateLimitData, 
    77TB_tmp, 
     
    9090            widgetHTML += '<div class="tb_footer">'; 
    9191            if (!TB_config.archive_is_disabled) { 
     92                 
     93                if (typeof(TB_config.widgets[widgetId].viewMoreText) == 'undefined') { 
     94                    TB_config.widgets[widgetId].viewMoreText = TB_labels.view_more + ' &raquo;'; 
     95                } 
     96                 
    9297                if (TB_config.widgets[widgetId].viewMoreUrl) { 
    93                     widgetHTML += '<a class="tb_archivelink" href="' + TB_config.widgets[widgetId].viewMoreUrl + '">view more &raquo;</a>'; 
     98                    widgetHTML += '<a class="tb_archivelink" href="' + TB_config.widgets[widgetId].viewMoreUrl + '">' + TB_config.widgets[widgetId].viewMoreText + '</a>'; 
    9499                } 
    95100                else if (TB_config.default_view_more_url) { 
    96                     widgetHTML += '<a class="tb_archivelink" href="' + TB_config.default_view_more_url + '">view more &raquo;</a>'; 
     101                    widgetHTML += '<a class="tb_archivelink" href="' + TB_config.default_view_more_url + '">' + TB_config.widgets[widgetId].viewMoreText + '</a>'; 
    97102                } 
    98103            } 
     
    387392    // check private 
    388393    if (isPrivateSrc) { 
    389         queryData.private = 1; 
     394        queryData.is_private = 1; 
    390395    } 
    391396 
     
    465470            'url': 'http://api.twitter.com/1/statuses/user_timeline.json', 
    466471            'source':src, 
    467             'private':0, 
     472            'privateSrc':0, 
    468473            'dtype':'jsonp', 
    469474            'modifier':modifier 
     
    486491            'url': 'http://api.twitter.com/1/favorites/' + queryData.screen_name + '.json', 
    487492            'source':src, 
    488             'private':0, 
     493            'privateSrc':0, 
    489494            'dtype':'jsonp', 
    490495            'modifier':modifier 
     
    701706function TB_addTweets(widgetId,jsonData,urlInfo) { 
    702707 
    703     var i, 
    704     tweets = jsonData, 
    705     originalTweet, 
     708    var tweets = jsonData, 
    706709    isNewTweet = false, 
    707     tweetUser, 
    708     badStrings, 
    709710    tb_tweet, 
    710711    tweetExists; 
     
    11991200     */ 
    12001201    this.isOKtoShow = function() { 
     1202         
     1203        var i; 
    12011204 
    12021205        // if we have a modifier on that source and text contains it 
  • tweet-blender/trunk/js/main.min.js

    r312556 r427446  
    1 var TB_version="3.1.17",TB_rateLimitData,TB_tmp,TB_mode="widget",TB_started=false,TB_monthNumber={Jan:1,Feb:2,Mar:3,Apr:4,May:5,Jun:6,Jul:7,Aug:8,Sep:9,Oct:10,Nov:11,Dec:12},TB_timePeriods=new Array("second","minute","hour","day","week","month","year","decade"),TB_timePeriodLengths=new Array("60","60","24","7","4.35","12","10"),TB_tweetsToCache=new Object(),TB_allSources=new Array(),jQnc=jQuery.noConflict(),sourceCounts=new Array(),TB_sourceNames=new Array();function TB_start(){if(TB_started){return}else{TB_started=true}if(typeof(TB_config)=="undefined"){TB_showMessage(null,"noconf","No configuration settings found.",true);return}TB_config.widgets=new Object();jQuery.each(jQuery("form.tb-widget-configuration"),function(d,f){var b=f.id,e,c,a=false;if(jQuery("#"+f.id).next().length>0){if(jQuery("#"+f.id).next().attr("id")!=""){if(jQuery("#"+f.id).next().attr("id").indexOf("-mc")>0){e=b.substr(0,b.length-2)}else{a=true;e=b}}else{a=true;e=b}}else{a=true;e=b}TB_config.widgets[e]=new Object;jQuery.each(jQuery("#"+b).children("input"),function(g,h){TB_config.widgets[e][h.name]=h.value});jQuery.each(jQuery("#"+b+" > div").children("input"),function(g,h){TB_config.widgets[e][h.name]=h.value});if(typeof(TB_config.widgets[e].sources)!="undefined"){TB_allSources=TB_allSources.concat(TB_config.widgets[e].sources.split(","))}if(a){c='<div id="'+e+'-mc"><div class="tb_header"><img class="tb_twitterlogo" src="'+TB_pluginPath+'/img/twitter-logo.png" alt="Twitter Logo" /><div class="tb_tools" style="background-image:url('+TB_pluginPath+'/img/bg_sm.png)"><a class="tb_infolink" href="http://kirill-novitchenko.com" title="Tweet Blender by Kirill Novitchenko" style="background-image:url('+TB_pluginPath+'/img/info-kino.png)"> </a><a class="tb_refreshlink" href="javascript:TB_blend(\''+e+'\');" title="Refresh Tweets"><img src="'+TB_pluginPath+'/img/ajax-refresh-icon.gif" alt="Refresh" /></a></div></div>';if(TB_config.general_seo_tweets_googleoff){tweetHTML+='<!--googleoff: index--><div class="tb_tweetlist"></div><!--googleon: index-->'}else{c+='<div class="tb_tweetlist"></div>'}c+='<div class="tb_footer">';if(!TB_config.archive_is_disabled){if(TB_config.widgets[e].viewMoreUrl){c+='<a class="tb_archivelink" href="'+TB_config.widgets[e].viewMoreUrl+'">view more &raquo;</a>'}else{if(TB_config.default_view_more_url){c+='<a class="tb_archivelink" href="'+TB_config.default_view_more_url+'">view more &raquo;</a>'}}}c+="</div></div>";jQuery("#"+f.id).after(c)}});if(TB_getObjectSize(TB_config.widgets)<1){return}TB_allSources=TB_getUniqueElements(TB_allSources);jQuery("div.tb_tools").css("background-image","url("+TB_pluginPath+"/img/bg.png)").width(56);jQuery("a.tb_infolink").css("display","inline").css("margin-right","11px");if(typeof(jQuery.toJSON)=="undefined"&&typeof(jQnc.toJSON)=="function"){jQuery.toJSON=jQnc.toJSON}if(!TB_config.default_view_more_url){jQuery("a.defaultUrl").hide()}if(typeof(TB_config)!="undefined"){if(TB_config.advanced_reroute_on){TB_config.rate_limit_url={url:TB_pluginPath+"/ws.php?action=rate_limit_status",dtype:"json"}}else{TB_config.rate_limit_url={url:"http://twitter.com/account/rate_limit_status.json",dtype:"jsonp"}}for(widgetId in TB_config.widgets){if(typeof(TB_config.widgets[widgetId].sources)=="undefined"||TB_config.widgets[widgetId].sources==""){TB_showMessage(widgetId,"nosrc","Twitter sources to blend are not defined",true)}else{TB_initInfoBox(widgetId);TB_makeAjaxURLs(widgetId);TB_config.widgets[widgetId]["minTweetId"]=0;TB_config.widgets[widgetId]["maxTweetId"]=0;if(jQuery("#"+widgetId+"-mc > div.tb_tweetlist > div.tb_tweet").size()>0){if(TB_tmp=parseInt(jQuery("#"+widgetId+"-mc > div.tb_tweetlist > div:last").attr("id").substr(1))){TB_config.widgets[widgetId]["minTweetId"]=TB_tmp}if(TB_tmp=parseInt(jQuery("#"+widgetId+"-mc > div.tb_tweetlist > div:first").attr("id").substr(1))){TB_config.widgets[widgetId]["maxTweetId"]=TB_tmp}if(typeof(TB_customFormat)=="function"){jQuery.each(jQuery("#"+widgetId+"-mc > div.tb_tweetlist").children("div"),function(a,b){jQuery("#"+b.id).html(TB_customFormat(b.innerHTML))})}}TB_config.widgets[widgetId]["tweetsShown"]=jQuery("#"+widgetId+"-mc > div.tb_tweetlist").children("div").size();jQuery.each(jQuery("#"+widgetId+"-mc > div.tb_tweetlist").children("div"),function(a,b){TB_wireMouseOver(b.id.substr(1))});jQuery("a.tb_photo, .tb_author a, .tb_msg a, .tweet-tools a, .tb_infolink").click(function(){this.target="_blank"});if(parseInt(TB_config.widgets[widgetId].refreshRate)>1){setInterval("TB_blend('"+widgetId+"');",parseInt(TB_config.widgets[widgetId].refreshRate)*1000)}if(parseInt(TB_config.widgets[widgetId].refreshRate)==1||TB_config.widgets[widgetId].tweetsShown<TB_config.widgets[widgetId].tweetsNum){TB_blend(widgetId)}}}}else{TB_showMessage(null,"noconf","Cannot retrieve Tweet Blender configuration options",true);jQuery("a.tb_refreshlink").remove();jQuery("div.tb_tools").css("background-image","url("+TB_pluginPath+"/img/bg_sm.png)").width(28)}}function TB_makeAjaxURLs(f){var h=new Array(),g=new Array(),b=new Array(),c="",a="",e,d;TB_config.widgets[f]["ajaxURLs"]=new Array();jQuery.each(TB_config.widgets[f].sources.split(","),function(j,k){k=jQuery.trim(k);if(k.charAt(0)=="!"){if((e=k.indexOf(":"))>0){c=k.substr(2,e-1);TB_sourceNames[c.toLowerCase()]=k.substr(e+1);k=k.substr(1,e-1)}else{c=k.substr(2)}if(TB_config.widgets[f].favoritesOnly){TB_addAjaxUrl(f,"favorites",c,k,1)}else{if(TB_config.advanced_no_search_api){TB_addAjaxUrl(f,"user_timeline","screen_name="+c,k,1)}else{TB_addAjaxUrl(f,"search","&from="+c,k,1)}}}else{if(k.charAt(0)=="@"&&k.indexOf("/")==-1){if(TB_config.widgets[f].favoritesOnly){if((e=k.indexOf(":"))>0){c=k.substr(1,e-1);TB_sourceNames[c.toLowerCase()]=k.substr(e+1);k=k.substr(0,e)}else{c=k.substr(1)}TB_addAjaxUrl(f,"favorites",c,k,0)}else{if((d=k.indexOf("|"))>1){if((e=k.indexOf(":"))>0){c=k.substr(1,d-1);a=k.substr(d+1,(e-d-1));TB_sourceNames[c.toLowerCase()]=k.substr(e+1);k=k.substr(0,e)}else{c=k.substr(1,d-1);a=k.substr(d+1)}if(a.charAt(0)=="#"){TB_addAjaxUrl(f,"search","&from="+c+"&tag="+a.substr(1),k,0)}else{TB_addAjaxUrl(f,"search","&from="+c+"&ors="+a,k,0)}}else{if((e=k.indexOf(":"))>0){c=k.substr(1,e-1);TB_sourceNames[c.toLowerCase()]=k.substr(e+1);k=k.substr(1,e-1)}else{c=k.substr(1)}if(TB_config.advanced_no_search_api){TB_addAjaxUrl(f,"user_timeline","screen_name="+c,k,0)}else{if(escape(g.join(" OR ")).length+k.length>140){TB_addAjaxUrl(f,"search","&q="+escape(g.join(" OR ")),escape("@"+b.join(",@")),0);b=new Array();g=new Array()}b.push(c);if(TB_config.filter_hide_mentions){g.push("from:"+c)}else{g.push(k+" OR from:"+c)}}}}}else{if(k.charAt(0)=="@"&&k.indexOf("/")>1){if(TB_config.advanced_reroute_on||TB_config.reached_api_limit){TB_addAjaxUrl(f,"list_timeline","&user="+k.substr(1,k.indexOf("/")-1)+"&list="+k.substr(k.indexOf("/")+1),k,0)}else{TB_addAjaxUrl(f,"list_timeline",k.substr(1,k.indexOf("/")-1)+"/lists/"+k.substr(k.indexOf("/")+1)+"/statuses.json",k,0)}}else{if(k!=""){if(escape(h.join(" ")).length+k.length>140){TB_addAjaxUrl(f,"search","&ors="+escape(h.join(" ")),escape(h.join(",")),0);h=new Array()}h.push(k)}}}}});if(h.length>0){TB_addAjaxUrl(f,"search","&ors="+escape(h.join(" ")),escape(h.join(",")),0)}if(b.length>0){TB_addAjaxUrl(f,"search","&q="+escape(g.join(" OR ")),escape("@"+b.join(",@")),0)}}function TB_addAjaxUrl(f,c,e,b,g){var i="",d="",h="",a="";if(typeof(TB_config.filter_lang)!="undefined"&&TB_config.filter_lang.length==2){i="&lang="+TB_config.filter_lang}else{i="&lang=all"}if(typeof(TB_config.filter_bad_strings)!="undefined"&&TB_config.filter_bad_strings.length>0){h="&nots="+escape(TB_config.filter_bad_strings.split(",").join(" "))}if(g){a="&private=1"}if(c=="search"&&(TB_config.advanced_reroute_on||TB_config.reached_api_limit||g)){TB_config.widgets[f]["ajaxURLs"].push({url:TB_pluginPath+"/ws.php?action=search"+e+i+d+h+a,source:b,privateSrc:g,dtype:"json"})}else{if(c=="search"){TB_config.widgets[f]["ajaxURLs"].push({url:"http://search.twitter.com/search.json?"+d+e+i+h,source:b,privateSrc:0,dtype:"jsonp"})}else{if(c=="list_timeline"&&(TB_config.advanced_reroute_on||TB_config.reached_api_limit)){TB_config.widgets[f]["ajaxURLs"].push({url:TB_pluginPath+"/ws.php?action=list_timeline"+e,source:b,privateSrc:0,dtype:"json"})}else{if(c=="list_timeline"){TB_config.widgets[f]["ajaxURLs"].push({url:"http://api.twitter.com/1/"+e,source:b,privateSrc:0,dtype:"jsonp"})}else{if(c=="user_timeline"&&(TB_config.advanced_reroute_on||TB_config.reached_api_limit||g)){TB_config.widgets[f]["ajaxURLs"].push({url:TB_pluginPath+"/ws.php?action=user_timeline&"+e,source:b,privateSrc:0,dtype:"json"})}else{if(c=="user_timeline"){TB_config.widgets[f]["ajaxURLs"].push({url:"http://twitter.com/statuses/user_timeline.json?"+e,source:b,"private":0,dtype:"jsonp"})}else{if(c=="favorites"&&(TB_config.advanced_reroute_on||TB_config.reached_api_limit||g)){TB_config.widgets[f]["ajaxURLs"].push({url:TB_pluginPath+"/ws.php?action=favorites&user="+e,source:b,privateSrc:0,dtype:"json"})}else{if(c=="favorites"){TB_config.widgets[f]["ajaxURLs"].push({url:"http://api.twitter.com/1/favorites/"+e+".json",source:b,"private":0,dtype:"jsonp"})}}}}}}}}}function TB_initInfoBox(a){TB_config.widgets[a].sourcesHTML="";TB_config.widgets[a].sourcesCount=0;jQuery.each(TB_config.widgets[a].sources.split(","),function(b,c){if(c.charAt(0)=="!"){c=c.substr(1)}if((colonPos=c.indexOf(":"))>0){c=c.substr(0,colonPos)}if((pipePos=c.indexOf("|"))>0){c=c.substr(0,pipePos)}TB_config.widgets[a].sourcesHTML+='<a href="';if(c.charAt(0)=="@"){TB_config.widgets[a].sourcesHTML+="http://twitter.com/"+c.substr(1)}else{TB_config.widgets[a].sourcesHTML+="http://search.twitter.com/search?q="+escape(c)}TB_config.widgets[a].sourcesHTML+='">'+c+"</a> ";TB_config.widgets[a].sourcesCount++});jQuery("#"+a+"-mc").children("div.tb_header").children("img.tb_twitterlogo").click(function(){TB_showMessage(a,"info","Powered by Tweet Blender plugin v"+TB_version+" blending "+TB_config.widgets[a].sourcesHTML,false)})}function TB_blend(a){TB_showLoader(a);if(!TB_config.advanced_reroute_on&&!TB_config.reached_api_limit){jQuery.ajax({url:TB_config.rate_limit_url.url,dataType:TB_config.rate_limit_url.dtype,success:function(d){if(d.error||d.remaining_hits<TB_config.widgets[a].ajaxURLs.length){TB_config.reached_api_limit=true;if(!TB_config.advanced_disable_cache){var e=1000*60*5,c=new Date(),b;if(d.reset_time){b=TB_str2date(d.reset_time);e=Math.round(b.getTime()-c.getTime())}setTimeout("TB_config.reached_api_limit=false;TB_makeAjaxURLs('"+a+"');TB_blend('"+a+"');",e);TB_makeAjaxURLs(a);TB_getTweets(a)}else{if(TB_config.advanced_show_limit_msg){TB_showMessage(a,"limit","You reached Twitter API connection limit. Next reset "+TB_verbalTime(TB_str2date(d.reset_time)),false)}}}else{TB_getTweets(a)}},error:function(){TB_getTweets(a)}})}else{TB_getTweets(a)}}function TB_checkComplete(a){if(TB_config.widgets[a].urlsDone==TB_config.widgets[a].ajaxURLs.length){TB_hideLoader(a);if(jQuery("#"+a+"-mc > div.tb_tweetlist").children("div").size()==0){TB_showMessage(a,"notweets","No tweets found for "+TB_config.widgets[a].sourcesHTML,true)}else{TB_hideMessage(a,"notweets");if(!TB_config.advanced_disable_cache){TB_cacheNewTweets()}}}}function TB_getTweets(a){TB_config.widgets[a]["urlsDone"]=0;jQuery.each(TB_config.widgets[a].ajaxURLs,function(c,b){jQuery.ajax({dataType:b.dtype,url:b.url,success:function(d){if(d.error){if(d.error.indexOf("Rate limit exceeded")==0){TB_config.reached_api_limit=true}TB_config.widgets[a].urlsDone++;TB_checkComplete(a)}else{TB_addTweets(a,d,b)}},error:function(){TB_config.widgets[a].urlsDone++;TB_checkComplete(a)}})})}function TB_cacheNewTweets(){if(TB_getObjectSize(TB_tweetsToCache)>0){jQuery.ajax({url:TB_pluginPath+"/ws.php?action=cache_data",type:"POST",dataType:"json",data:({tweets:jQuery.toJSON(TB_tweetsToCache)}),success:function(a){if(!a.error){TB_tweetsToCache=new Object()}}})}}function TB_addTweets(d,c,a){var f=c,b,e=false,g;if(typeof(c.results)!="undefined"){f=c.results}jQuery.each(f,function(j,l){if(typeof(l.user)=="undefined"){if(l.from_user){l.user={screen_name:l.from_user}}else{l.user={screen_name:""}}}if(TB_config.filter_limit_per_source>0){g=l.user.screen_name;if(typeof(sourceCounts[g])!="undefined"||sourceCounts[g]==0){if(sourceCounts[g]>=TB_config.filter_limit_per_source){return true}else{sourceCounts[g]++}}else{sourceCounts[g]=1;if(TB_config.widget_limit_per_source_time>0){setTimeout('sourceCounts["'+g+'"]=0',TB_config.widget_limit_per_source_time*1000)}}}e=false;b=jQuery.extend(true,{},l);if(TB_config.filter_hide_replies&&(l.in_reply_to_user_id||l.to_user_id)){return true}if(jQuery("#t"+l.id.toString()).length>0){return true}else{if(TB_config.widgets[d].tweetsShown==0){TB_config.widgets[d].tweetsShown++;TB_config.widgets[d].minTweetId=l.id;TB_config.widgets[d].maxTweetId=l.id;jQuery("#"+d+"-mc > div.tb_tweetlist").append(TB_makeHTML(l));e=true}else{if(TB_config.widgets[d].minTweetId>0&&l.id<TB_config.widgets[d].minTweetId){if(TB_config.widgets[d].tweetsShown>=TB_config.widgets[d].tweetsNum){return false}else{TB_config.widgets[d].tweetsShown++;jQuery("#"+d+"-mc > div.tb_tweetlist").append(TB_makeHTML(l));TB_config.widgets[d].minTweetId=l.id;if(TB_config.widgets[d].tweetsNum==1){TB_config.widgets[d].maxTweetId=l.id}e=true}}else{if(TB_config.widgets[d].maxTweetId>0&&l.id>TB_config.widgets[d].maxTweetId){TB_enforceLimit(d);jQuery("#"+d+"-mc > div.tb_tweetlist").prepend(TB_makeHTML(l));TB_config.widgets[d].tweetsShown++;TB_config.widgets[d].maxTweetId=l.id;if(TB_config.widgets[d].tweetsNum==1){TB_config.widgets[d].minTweetId=l.id}e=true}else{TB_enforceLimit(d);var h=TB_config.widgets[d].maxTweetId,k;jQuery("#"+d+"-mc > div.tb_tweetlist > div.tb_tweet").each(function(m,n){k=n.id.substr(1);if(l.id<h&&l.id>k){jQuery("#t"+h.toString()).after(TB_makeHTML(l));TB_config.widgets[d].tweetsShown++;return false}h=k});if(jQuery("#t"+l.id.toString()).length<=0){jQuery("#t"+TB_config.widgets[d].minTweetId.toString()).after(TB_makeHTML(l));TB_config.widgets[d].minTweetId=l.id;if(TB_config.widgets[d].tweetsNum==1){TB_config.widgets[d].maxTweetId=l.id}TB_config.widgets[d].tweetsShown++}e=true}}}}if(e&&!TB_config.advanced_disable_cache){TB_tweetsToCache[l.id.toString()]={s:a.source,p:a.privateSrc,t:b}}TB_wireMouseOver(l.id)});TB_config.widgets[d].urlsDone++;jQuery("a.tb_photo, .tb_author a, .tb_msg a, .tweet-tools a, .tb_infolink").click(function(){this.target="_blank"});TB_checkComplete(d)}function TB_wireMouseOver(a){if(TB_config[TB_mode+"_show_reply_link"]||TB_config[TB_mode+"_show_follow_link"]){jQuery("#t"+a.toString()).hover(function(){jQuery(this).find("div:last").slideDown()},function(){jQuery(this).find("div:last").slideUp()})}}function TB_enforceLimit(b){if(TB_config.widgets[b].tweetsShown==TB_config.widgets[b].tweetsNum){var a=jQuery("#t"+TB_config.widgets[b].minTweetId.toString()),c=a.prev("div.tb_tweet");a.remove();TB_config.widgets[b].tweetsShown--;delete TB_tweetsToCache[TB_config.widgets[b].minTweetId.toString()];if(TB_config.widgets[b].tweetsShown==0){TB_config.widgets[b].minTweetId=0;TB_config.widgets[b].maxTweetId=0;return}else{if(c.length>0){TB_config.widgets[b].minTweetId=parseInt(c.attr("id").substr(1))}}}}function TB_makeHTML(e){var d="",b,c,a;b='<div class="tb_tweet" id="t'+e.id.toString()+'">';if(TB_config.widget_show_photos){if(!e.user.profile_image_url&&e.profile_image_url){e.user.profile_image_url=e.profile_image_url}d+='<a class="tb_photo" rel="nofollow" href="http://twitter.com/'+e.user.screen_name+'">';d+='<img src="'+e.user.profile_image_url+'" alt="'+e.user.screen_name+'" />';d+="</a>"}if(TB_config.widget_show_user){if(typeof(TB_sourceNames[e.user.screen_name.toLowerCase()])!="undefined"){d+='<span class="tb_author"><a rel="nofollow" href="http://twitter.com/'+e.user.screen_name+'">'+TB_sourceNames[e.user.screen_name.toLowerCase()]+"</a>: </span> "}else{d+='<span class="tb_author"><a rel="nofollow" href="http://twitter.com/'+e.user.screen_name+'">'+e.user.screen_name+"</a>: </span> "}}if(TB_config.general_link_urls){e.text=e.text.replace(/(https?:\/\/\S+)/gi,'<a rel="nofollow" href="$1">$1</a>')}if(TB_config.general_link_screen_names){e.text=e.text.replace(/\@([\w]+)/gi,'<a rel="nofollow" href="http://twitter.com/$1">@$1</a>')}if(TB_config.general_link_hash_tags){e.text=e.text.replace(/\#([\w\-]+)/gi,'<a rel="nofollow" href="http://search.twitter.com/search?q=%23$1">#$1</a>')}d+='<span class="tb_msg">'+e.text+"</span><br/>";if(!TB_config.general_seo_tweets_googleoff&&TB_config.general_seo_footer_googleoff){d+="<!--googleoff: index-->"}d+=' <span class="tb_tweet-info">';d+='<a rel="nofollow" href="http://twitter.com/'+e.user.screen_name+"/statuses/"+e.id.toString()+'">';a=TB_str2date(e.created_at);if(TB_config.general_timestamp_format){if(typeof(jQuery.PHPDate)!="undefined"){d+=jQuery.PHPDate(TB_config.general_timestamp_format,a)}else{if(typeof(jQnc.PHPDate)!="undefined"){d+=jQnc.PHPDate(TB_config.general_timestamp_format,a)}}}else{d+=TB_verbalTime(a)}d+="</a>";if(TB_config.widget_show_source&&e.source){d+=" from ";if(e.source.indexOf("&lt;")>=0){d+=jQuery("<textarea/>").html(e.source).val()}else{d+=e.source}}d+="</span>";if(!TB_config.general_seo_tweets_googleoff&&TB_config.general_seo_footer_googleoff){d+="<!--googleon: index-->"}if(TB_config.widget_show_follow_link||TB_config.widget_show_reply_link){d+='<div class="tweet-tools" style="display:none;">';if(TB_config.widget_show_reply_link){d+='<a rel="nofollow" href="http://twitter.com/home?status=@'+e.user.screen_name+"%20&in_reply_to_status_id="+e.id.toString()+"&in_reply_to="+e.user.screen_name+'">reply</a>'}if(TB_config.widget_show_follow_link&&TB_config.widget_show_reply_link){d+=" | "}if(TB_config.widget_show_follow_link){d+='<a rel="nofollow" href="http://twitter.com/'+e.user.screen_name+'">follow '+e.user.screen_name+"</a>"}d+="</div>"}c="</div>\n";if(typeof(TB_customFormat)=="function"){d=TB_customFormat(d)}return b+d+c}function TB_showLoader(a){if(TB_config.widgets[a].tweetsShown==0){TB_showMessage(a,"loading","Loading tweets...",true)}jQuery("#"+a+"-mc > div.tb_header > div.tb_tools > a.tb_refreshlink > img").attr("src",TB_pluginPath+"/img/ajax-refresh.gif");jQuery("#"+a+"-mc > div.tb_header > div.tb_tools > a.tb_refreshlink").addClass("loading")}function TB_hideLoader(a){TB_hideMessage(a,"loading");jQuery("#"+a+"-mc > div.tb_header > div.tb_tools > a.tb_refreshlink > img").attr("src",TB_pluginPath+"/img/ajax-refresh-icon.gif");jQuery("#"+a+"-mc > div.tb_header > div.tb_tools > a.tb_refreshlink").removeClass("loading")}function TB_showMessage(b,a,d,c){if(!b){jQuery("div.tb_tweetlist").before('<div id="msg_'+a+'" class="tb_msg" style="display:none;">'+d+"</div>");return}if(!jQuery("#"+b+"-mc").children("#msg_"+a).length){jQuery("#"+b+"-mc").children("div.tb_tweetlist").before('<div id="msg_'+a+'" class="tb_msg" style="display:none;">'+d+"</div>");jQuery("#"+b+"-mc").children("#msg_"+a).slideDown();if(!c){setTimeout('TB_hideMessage("'+b+'","'+a+'")',8000)}}else{if(jQuery("#"+b+"-mc").children("#msg_"+a).is(":hidden")){jQuery("#"+b+"-mc").children("#msg_"+a).slideDown()}}}function TB_hideAllMessages(){jQuery("div.tb_msg").slideUp(1000,function(){jQuery("div.tb_msg").remove()})}function TB_hideMessage(b,a){jQuery("#"+b+"-mc").children("#msg_"+a).slideUp(1000,function(){jQuery("#"+b+"-mc").children("#msg_"+a).remove()})}function TB_str2date(c){var a=new Date(),b=c.split(/[\s\:]/);if(c.indexOf(",")>=0){a.setUTCFullYear(b[3],TB_monthNumber[""+b[2]]-1,b[1]);a.setUTCHours(b[4],b[5],b[6])}else{a.setUTCFullYear(b[7],TB_monthNumber[""+b[1]]-1,b[2]);a.setUTCHours(b[3],b[4],b[5])}return a}function TB_verbalTime(a){var c,b=new Date(),g,d,e="",f="";if(b.getTime()>a.getTime()){g=Math.round((b.getTime()-a.getTime())/1000);f=" ago"}else{g=Math.round((a.getTime()-b.getTime())/1000);e="in "}for(c=0;g>=TB_timePeriodLengths[c]&&c<TB_timePeriodLengths.length;c++){g=g/TB_timePeriodLengths[c]}g=Math.round(g);d=TB_timePeriods[c];if(g!=1){d+="s"}return e+g+" "+d+f}function TB_addLoadEvent(a){var b=window.onload;if(typeof window.onload!="function"){window.onload=a}else{window.onload=function(){b();a()}}}function TB_getObjectSize(c){var b=0,a;for(a in c){if(c.hasOwnProperty(a)){b++}}return b}function TB_getUniqueElements(a){var d=[],b,c;for(b=a.length;b--;){c=a[b];if(jQuery.inArray(c,d)===-1){d.unshift(c)}}return d}TB_addLoadEvent(TB_start);jQuery(document).ready(TB_start); 
     1var TB_version="3.3.15",TB_rateLimitData,TB_tmp,TB_mode="widget",TB_started=false,TB_tweetsToCache=new Object(),TB_allSources=new Array(),jQnc=jQuery,TB_sourceCounts=new Array(),TB_sourceNames=new Array(),TB_seenTweets=new Array();function TB_start(){if(TB_started){return}else{TB_started=true}if(typeof(TB_config)=="undefined"){TB_showMessage(null,"noconf",TB_labels.no_config,true);return}TB_config.widgets=new Object();jQuery.each(jQuery("form.tb-widget-configuration"),function(d,g){var b=g.id,e,c,a=false,f=jQuery(g).next();if(f.length>0){if(typeof(f.attr("id"))!="undefined"&&f.attr("id")!=""){if(f.attr("id").indexOf("-mc")>0){e=b.substr(0,b.length-2)}else{a=true;e=b}}else{a=true;e=b}}else{a=true;e=b}TB_config.widgets[e]=new Object;jQuery.each(jQuery("#"+b).find("input"),function(h,i){TB_config.widgets[e][i.name]=i.value});if(typeof(TB_config.widgets[e].sources)!="undefined"){TB_allSources=TB_allSources.concat(TB_config.widgets[e].sources.split(","))}if(a){c='<div id="'+e+'-mc"><div class="tb_header"><img class="tb_twitterlogo" src="'+TB_pluginPath+'/img/twitter-logo.png" alt="'+TB_labels.twitter_logo+'" /><div class="tb_tools" style="background-image:url('+TB_pluginPath+'/img/bg_sm.png)"><a class="tb_infolink" href="http://kirill-novitchenko.com" title="'+TB_labels.kino+'" style="background-image:url('+TB_pluginPath+'/img/info-kino.png)"> </a><a class="tb_refreshlink" href="javascript:TB_blend(\''+e+'\');" title="'+TB_labels.refresh+'"><img src="'+TB_pluginPath+'/img/ajax-refresh-icon.gif" alt="'+TB_labels.refresh+'" /></a></div></div>';if(TB_config.general_seo_tweets_googleoff){tweetHTML+='<!--googleoff: index--><div class="tb_tweetlist"></div><!--googleon: index-->'}else{c+='<div class="tb_tweetlist"></div>'}c+='<div class="tb_footer">';if(!TB_config.archive_is_disabled){if(typeof(TB_config.widgets[e].viewMoreText)=="undefined"){TB_config.widgets[e].viewMoreText=TB_labels.view_more+" &raquo;"}if(TB_config.widgets[e].viewMoreUrl){c+='<a class="tb_archivelink" href="'+TB_config.widgets[e].viewMoreUrl+'">'+TB_config.widgets[e].viewMoreText+"</a>"}else{if(TB_config.default_view_more_url){c+='<a class="tb_archivelink" href="'+TB_config.default_view_more_url+'">'+TB_config.widgets[e].viewMoreText+"</a>"}}}c+="</div></div>";jQuery("#"+g.id).after(c)}});if(TB_getObjectSize(TB_config.widgets)<1){return}TB_allSources=TB_getUniqueElements(TB_allSources);jQuery("div.tb_tools").css("background-image","url("+TB_pluginPath+"/img/bg.png)").width(56);jQuery("a.tb_infolink").css("display","inline").css("margin-right","11px");if(typeof(jQuery.toJSON)=="undefined"&&typeof(jQnc.toJSON)=="function"){jQuery.toJSON=jQnc.toJSON}if(typeof(jQuery.jsonp)=="undefined"&&typeof(jQnc.jsonp)=="function"){jQuery.jsonp=jQnc.jsonp}if(!TB_config.default_view_more_url){jQuery("a.defaultUrl").hide()}if(typeof(TB_config)!="undefined"){if(TB_config.advanced_reroute_on){TB_config.rate_limit_url={url:TB_pluginPath+"/ws.php?action=rate_limit_status",dtype:"json"}}else{TB_config.rate_limit_url={url:"http://twitter.com/account/rate_limit_status.json",dtype:"jsonp"}}for(widgetId in TB_config.widgets){if(typeof(TB_config.widgets[widgetId].sources)=="undefined"||TB_config.widgets[widgetId].sources==""){TB_showMessage(widgetId,"nosrc",TB_labels.no_sources,true)}else{TB_initInfoBox(widgetId);TB_makeAjaxURLs(widgetId);TB_config.widgets[widgetId]["minTweetId"]=0;TB_config.widgets[widgetId]["maxTweetId"]=0;if(jQuery("#"+widgetId+"-mc > div.tb_tweetlist > div.tb_tweet").size()>0){if(TB_tmp=jQuery("#"+widgetId+"-mc > div.tb_tweetlist > div:last").attr("id")){TB_config.widgets[widgetId]["minTweetId"]=TB_tmp}if(TB_tmp=jQuery("#"+widgetId+"-mc > div.tb_tweetlist > div:first").attr("id")){TB_config.widgets[widgetId]["maxTweetId"]=TB_tmp}}TB_config.widgets[widgetId]["tweetsShown"]=jQuery("#"+widgetId+"-mc > div.tb_tweetlist").children("div").size();jQuery.each(jQuery("#"+widgetId+"-mc > div.tb_tweetlist").children("div"),function(a,b){TB_wireMouseOver(b.id)});jQuery("a.tb_photo, .tb_author a, .tb_msg a, .tweet-tools a, .tb_infolink").click(function(){this.target="_blank"});if(parseInt(TB_config.widgets[widgetId].refreshRate)>1){setInterval("TB_blend('"+widgetId+"');",parseInt(TB_config.widgets[widgetId].refreshRate)*1000)}if(parseInt(TB_config.widgets[widgetId].refreshRate)==1||TB_config.widgets[widgetId].tweetsShown<TB_config.widgets[widgetId].tweetsNum){TB_blend(widgetId)}}}}else{TB_showMessage(null,"noconf",TB_labels.no_global_config,true);jQuery("a.tb_refreshlink").remove();jQuery("div.tb_tools").css("background-image","url("+TB_pluginPath+"/img/bg_sm.png)").width(28)}}function TB_makeAjaxURLs(f){var h=new Array(),g=new Array(),b=new Array(),c="",a="",e,d;TB_config.widgets[f]["ajaxURLs"]=new Array();jQuery.each(TB_config.widgets[f].sources.split(","),function(j,k){k=jQuery.trim(k);if(k.charAt(0)=="!"){if((e=k.indexOf(":"))>0){c=k.substr(2,e-1);TB_sourceNames[c.toLowerCase()]=k.substr(e+1);k=k.substr(1,e-1)}else{c=k.substr(2)}if(TB_config.widgets[f].favoritesOnly){TB_addAjaxUrl(f,"favorites",{screen_name:c},k,1,null)}else{if(TB_config.advanced_no_search_api){TB_addAjaxUrl(f,"user_timeline",{screen_name:c},k,1,null)}else{TB_addAjaxUrl(f,"search",{from:c},k,1,null)}}}else{if(k.charAt(0)=="@"&&k.indexOf("/")==-1){if(TB_config.widgets[f].favoritesOnly){if((e=k.indexOf(":"))>0){c=k.substr(1,e-1);TB_sourceNames[c.toLowerCase()]=k.substr(e+1);k=k.substr(0,e)}else{c=k.substr(1)}TB_addAjaxUrl(f,"favorites",{screen_name:c},k,0,null)}else{if((d=k.indexOf("|"))>1){if((e=k.indexOf(":"))>0){c=k.substr(1,d-1);a=k.substr(d+1,(e-d-1));TB_sourceNames[c.toLowerCase()]=k.substr(e+1);k=k.substr(0,e)}else{c=k.substr(1,d-1);a=k.substr(d+1)}if(a.charAt(0)=="#"){TB_addAjaxUrl(f,"search",{from:c,tag:a.substr(1)},k,0,a)}else{TB_addAjaxUrl(f,"search",{from:c,ors:a},k,0,a)}}else{if((e=k.indexOf(":"))>0){c=k.substr(1,e-1);TB_sourceNames[c.toLowerCase()]=k.substr(e+1);k=k.substr(0,e)}else{c=k.substr(1)}if(TB_config.advanced_no_search_api){TB_addAjaxUrl(f,"user_timeline",{screen_name:c},k,0,null)}else{if(escape(g.join(" OR ")).length+k.length>140){TB_addAjaxUrl(f,"search",{q:g.join(" OR ")},escape("@"+b.join(",@")),0,null);b=new Array();g=new Array()}b.push(c);if(TB_config.filter_hide_mentions){g.push("from:"+c)}else{g.push(k+" OR from:"+c)}}}}}else{if(k.charAt(0)=="@"&&k.indexOf("/")>1){if((d=k.indexOf("|"))>1){TB_addAjaxUrl(f,"list_timeline",{user:k.substr(1,k.indexOf("/")-1),list:k.substr(k.indexOf("/")+1,d-k.indexOf("/")-1)},k,0,k.substr(d+1))}else{TB_addAjaxUrl(f,"list_timeline",{user:k.substr(1,k.indexOf("/")-1),list:k.substr(k.indexOf("/")+1)},k,0,null)}}else{if(k!=""){if(k.indexOf(" ")>0){if(k.charAt(0)!='"'){k='"'+k+'"'}}if(h.join(" OR ").length+k.length>140){TB_addAjaxUrl(f,"search",{q:h.join(" OR ")},h.join(","),0,null);h=new Array()}h.push(k)}}}}});if(h.length>0){TB_addAjaxUrl(f,"search",{q:h.join(" OR ")},h.join(","),0,null)}if(b.length>0){TB_addAjaxUrl(f,"search",{q:g.join(" OR ")},encodeURI("@"+b.join(",@")),0,null)}}function TB_addAjaxUrl(f,e,b,g,d,a){var c;if(typeof(TB_config.filter_lang)!="undefined"&&TB_config.filter_lang.length==2){b.lang=TB_config.filter_lang}else{b.lang="all"}if(d){b.is_private=1}if(e=="search"&&(TB_config.advanced_reroute_on||TB_config.reached_api_limit||d)){b.action=e;TB_config.widgets[f]["ajaxURLs"].push({url:TB_pluginPath+"/ws.php",data:b,source:g,privateSrc:d,dtype:"json",modifier:a})}else{if(e=="search"){b.rpp=TB_config.widgets[f]["tweetsNum"]*2;TB_config.widgets[f]["ajaxURLs"].push({url:"http://search.twitter.com/search.json",data:b,source:g,privateSrc:0,dtype:"jsonp",modifier:a})}else{if(e=="list_timeline"&&(TB_config.advanced_reroute_on||TB_config.reached_api_limit)){b.action=e;delete b.user;delete b.list;delete b.nots;delete b.lang;TB_config.widgets[f]["ajaxURLs"].push({url:TB_pluginPath+"/ws.php",data:b,source:g,privateSrc:0,dtype:"json",modifier:a})}else{if(e=="list_timeline"){c="http://api.twitter.com/1/"+b.user+"/lists/"+b.list+"/statuses.json";delete b.user;delete b.list;delete b.nots;delete b.lang;b.per_page=TB_config.widgets[f]["tweetsNum"]*2;TB_config.widgets[f]["ajaxURLs"].push({url:c,data:b,source:g,privateSrc:0,dtype:"jsonp",modifier:a})}else{if(e=="user_timeline"&&(TB_config.advanced_reroute_on||TB_config.reached_api_limit||d)){b.action=e;TB_config.widgets[f]["ajaxURLs"].push({url:TB_pluginPath+"/ws.php",data:b,source:g,privateSrc:0,dtype:"json",modifier:a})}else{if(e=="user_timeline"){TB_config.widgets[f]["ajaxURLs"].push({data:b,url:"http://api.twitter.com/1/statuses/user_timeline.json",source:g,privateSrc:0,dtype:"jsonp",modifier:a})}else{if(e=="favorites"&&(TB_config.advanced_reroute_on||TB_config.reached_api_limit||d)){b.action=e;TB_config.widgets[f]["ajaxURLs"].push({data:b,url:TB_pluginPath+"/ws.php",source:g,privateSrc:0,dtype:"json",modifier:a})}else{if(e=="favorites"){TB_config.widgets[f]["ajaxURLs"].push({data:{},url:"http://api.twitter.com/1/favorites/"+b.screen_name+".json",source:g,privateSrc:0,dtype:"jsonp",modifier:a})}}}}}}}}}function TB_initInfoBox(a){TB_config.widgets[a].sourcesHTML="";TB_config.widgets[a].sourcesCount=0;jQuery.each(TB_config.widgets[a].sources.split(","),function(b,c){if(c.charAt(0)=="!"){c=c.substr(1)}if((colonPos=c.indexOf(":"))>0){c=c.substr(0,colonPos)}if((pipePos=c.indexOf("|"))>0){c=c.substr(0,pipePos)}TB_config.widgets[a].sourcesHTML+='<a href="';if(c.charAt(0)=="@"){TB_config.widgets[a].sourcesHTML+="http://twitter.com/"+c.substr(1)}else{TB_config.widgets[a].sourcesHTML+="http://search.twitter.com/search?q="+escape(c)}TB_config.widgets[a].sourcesHTML+='">'+c+"</a> ";TB_config.widgets[a].sourcesCount++});jQuery("#"+a+"-mc").children("div.tb_header").children("img.tb_twitterlogo").click(function(){TB_showMessage(a,"info",TB_labels.version_msg.format(TB_version,TB_config.widgets[a].sourcesHTML),false)})}function TB_blend(a){TB_showLoader(a);if(!TB_config.advanced_reroute_on&&!TB_config.reached_api_limit){jQuery.ajax({url:TB_config.rate_limit_url.url,dataType:TB_config.rate_limit_url.dtype,success:function(d){if(d.error||d.remaining_hits<TB_config.widgets[a].ajaxURLs.length){TB_config.reached_api_limit=true;if(!TB_config.advanced_disable_cache){var e=1000*60*5,c=new Date(),b;if(d.reset_time){b=TB_str2date(d.reset_time);e=Math.round(b.getTime()-c.getTime())}setTimeout("TB_config.reached_api_limit=false;TB_makeAjaxURLs('"+a+"');TB_blend('"+a+"');",e);TB_makeAjaxURLs(a);TB_getTweets(a)}else{if(TB_config.advanced_show_limit_msg){TB_showMessage(a,"limit",TB_labels.limit_msg+". "+TB_labels.limit_reset.format(TB_verbalTime(TB_str2date(d.reset_time))),false)}}}else{TB_getTweets(a)}},error:function(){TB_getTweets(a)}})}else{TB_getTweets(a)}}function TB_checkComplete(a){if(TB_config.widgets[a].urlsDone==TB_config.widgets[a].ajaxURLs.length){TB_hideLoader(a);if(jQuery("#"+a+"-mc > div.tb_tweetlist").children("div").size()==0){TB_showMessage(a,"notweets",TB_labels.no_tweets_msg.format(TB_config.widgets[a].sourcesHTML),true)}else{TB_hideMessage(a,"notweets");if((typeof(TB_config.advanced_disable_cache)!="undefined"&&!TB_config.advanced_disable_cache)){TB_cacheNewTweets()}}}}function TB_getTweets(a){TB_config.widgets[a]["urlsDone"]=0;jQuery.each(TB_config.widgets[a].ajaxURLs,function(c,b){if(b.dtype=="jsonp"&&typeof(jQuery.jsonp)!="undefined"){jQuery.jsonp({data:b.data,callbackParameter:"callback",url:b.url,timeout:2000,success:function(d){if(d.error){if(d.error.indexOf("Rate limit exceeded")==0){TB_config.reached_api_limit=true}TB_config.widgets[a].urlsDone++;TB_checkComplete(a)}else{TB_addTweets(a,d,b)}},error:function(d,f,e){TB_config.widgets[a].urlsDone++;TB_checkComplete(a)}})}else{jQuery.ajax({data:b.data,dataType:b.dtype,url:b.url,timeout:2000,success:function(d){if(d.error){if(d.error.indexOf("Rate limit exceeded")==0){TB_config.reached_api_limit=true}TB_config.widgets[a].urlsDone++;TB_checkComplete(a)}else{TB_addTweets(a,d,b)}},error:function(d,f,e){TB_config.widgets[a].urlsDone++;TB_checkComplete(a)}})}})}function TB_cacheNewTweets(){if(TB_getObjectSize(TB_tweetsToCache)>0){if(typeof(jQuery.toJSON)=="undefined"&&typeof(jQnc.toJSON)=="function"){jQuery.toJSON=jQnc.toJSON}jQuery.ajax({url:TB_pluginPath+"/ws.php?action=cache_data",type:"POST",dataType:"json",data:({tweets:jQuery.toJSON(TB_tweetsToCache)}),success:function(a){if(!a.error){TB_tweetsToCache=new Object()}}})}}function TB_addTweets(e,d,a){var g=d,f=false,c,b;if(typeof(d.results)!="undefined"){g=d.results}jQuery.each(g,function(k,h){c=new TB_tweet(h);c.modifier=a.modifier;if(!c.isOKtoShow()){return true}c.selectRelevantSources(a.source);f=false;b=false;jQuery("div.tb_tweet").each(function(){if(c.isSameId(this.id)){b=true}});if(b){return true}if(TB_config.widgets[e].tweetsShown==0){TB_config.widgets[e].tweetsShown++;TB_config.widgets[e].minTweetId=c.divId;TB_config.widgets[e].maxTweetId=c.divId;jQuery("#"+e+"-mc > div.tb_tweetlist").append(c.getHTML());f=true}else{if(c.isOlderThan(TB_config.widgets[e].minTweetId)){if(TB_config.widgets[e].tweetsShown>=TB_config.widgets[e].tweetsNum){return false}else{TB_config.widgets[e].tweetsShown++;jQuery("#"+e+"-mc > div.tb_tweetlist").append(c.getHTML());TB_config.widgets[e].minTweetId=c.divId;if(TB_config.widgets[e].tweetsNum==1){TB_config.widgets[e].maxTweetId=c.divId}f=true}}else{if(c.isNewerThan(TB_config.widgets[e].maxTweetId)){TB_enforceLimit(e);jQuery("#"+e+"-mc > div.tb_tweetlist").prepend(c.getHTML());TB_config.widgets[e].tweetsShown++;TB_config.widgets[e].maxTweetId=c.divId;if(TB_config.widgets[e].tweetsNum==1){TB_config.widgets[e].minTweetId=c.divId}f=true}else{TB_enforceLimit(e);var j=TB_config.widgets[e].maxTweetId,l;jQuery("#"+e+"-mc > div.tb_tweetlist > div.tb_tweet").each(function(m,n){l=n.id;if(c.isOlderThan(j)&&c.isNewerThan(l)){jQuery("#"+j).after(c.getHTML());TB_config.widgets[e].tweetsShown++;return false}j=l});if(jQuery("#"+c.divId).length<=0){jQuery("#"+TB_config.widgets[e].minTweetId).after(c.getHTML());TB_config.widgets[e].minTweetId=c.divId;if(TB_config.widgets[e].tweetsNum==1){TB_config.widgets[e].maxTweetId=c.divId}TB_config.widgets[e].tweetsShown++}f=true}}}if(f&&(typeof(TB_config.advanced_disable_cache)!="undefined"&&!TB_config.advanced_disable_cache)){TB_tweetsToCache[c.divId]={s:c.sources,p:a.privateSrc,t:c.jsonCode}}TB_wireMouseOver(c.divId);if(TB_config.filter_hide_same_text){TB_seenTweets.push(c.jsonCode.text)}});TB_config.widgets[e].urlsDone++;jQuery("a.tb_photo, .tb_author a, .tb_msg a, .tweet-tools a, .tb_infolink").click(function(){this.target="_blank"});TB_checkComplete(e)}function TB_wireMouseOver(a){if(TB_config[TB_mode+"_show_reply_link"]||TB_config[TB_mode+"_show_follow_link"]){jQuery("#"+a).hover(function(){jQuery(this).find("div:last").slideDown()},function(){jQuery(this).find("div:last").slideUp()})}}function TB_enforceLimit(b){if(TB_config.widgets[b].tweetsShown==TB_config.widgets[b].tweetsNum){var a=jQuery("#"+TB_config.widgets[b].minTweetId),c=a.prev("div.tb_tweet");a.remove();TB_config.widgets[b].tweetsShown--;delete TB_tweetsToCache[TB_config.widgets[b].minTweetId];if(TB_config.widgets[b].tweetsShown==0){TB_config.widgets[b].minTweetId=0;TB_config.widgets[b].maxTweetId=0;return}else{if(c.length>0){TB_config.widgets[b].minTweetId=c.attr("id")}}}}function TB_showLoader(a){if(TB_config.widgets[a].tweetsShown==0){TB_showMessage(a,"loading",TB_labels.loading_msg,true)}jQuery("#"+a+"-mc > div.tb_header > div.tb_tools > a.tb_refreshlink > img").attr("src",TB_pluginPath+"/img/ajax-refresh.gif");jQuery("#"+a+"-mc > div.tb_header > div.tb_tools > a.tb_refreshlink").addClass("loading")}function TB_hideLoader(a){TB_hideMessage(a,"loading");jQuery("#"+a+"-mc > div.tb_header > div.tb_tools > a.tb_refreshlink > img").attr("src",TB_pluginPath+"/img/ajax-refresh-icon.gif");jQuery("#"+a+"-mc > div.tb_header > div.tb_tools > a.tb_refreshlink").removeClass("loading")}function TB_showMessage(b,a,d,c){if(!b){jQuery("div.tb_tweetlist").before('<div id="msg_'+a+'" class="tb_msg" style="display:none;">'+d+"</div>");return}if(!jQuery("#"+b+"-mc").children("#msg_"+a).length){jQuery("#"+b+"-mc").children("div.tb_tweetlist").before('<div id="msg_'+a+'" class="tb_msg" style="display:none;">'+d+"</div>");jQuery("#"+b+"-mc").children("#msg_"+a).slideDown();if(!c){setTimeout('TB_hideMessage("'+b+'","'+a+'")',8000)}}else{if(jQuery("#"+b+"-mc").children("#msg_"+a).is(":hidden")){jQuery("#"+b+"-mc").children("#msg_"+a).slideDown()}}}function TB_hideAllMessages(){jQuery("div.tb_msg").slideUp(1000,function(){jQuery("div.tb_msg").remove()})}function TB_hideMessage(b,a){jQuery("#"+b+"-mc").children("#msg_"+a).slideUp(1000,function(){jQuery("#"+b+"-mc").children("#msg_"+a).remove()})}function TB_tweet(a){this.jsonCode=a;this.tweetDate=TB_str2date(a.created_at);if(typeof(a.from_user)!="undefined"){this.screenName=a.from_user}else{if(typeof(a.user.screen_name)!="undefined"){this.screenName=a.user.screen_name}}this.id=a.id_str;this.sources="";this.selectRelevantSources=function(f){var e=new Array(),d="@"+this.screenName,c=this.jsonCode;jQuery.each(f.split(","),function(g,h){if(d==h||c.text.indexOf(h)>0){e.push(h)}});if(e.length>0){this.sources=e.join(",")}else{this.sources=f}};var b;if(TB_config.custom_template){b=TB_config.custom_template}else{b='<div id="{0}" class="tb_tweet">';if(TB_config.widget_show_photos){b+='<a class="tb_photo" rel="nofollow" href="http://twitter.com/{1}"><img src="{2}" alt="{1}"></a>'}if(TB_config.widget_show_user){b+='<span class="tb_author"><a rel="nofollow" href="http://twitter.com/{1}">{1}</a>: </span> '}b+='<span class="tb_msg">{3}</span><br />';if(!TB_config.general_seo_tweets_googleoff&&TB_config.general_seo_footer_googleoff){b+="<!--googleoff: index-->"}b+=' <span class="tb_tweet-info">';b+='<a rel="nofollow" href="http://twitter.com/{1}/statuses/{4}">{5}</a>';if(TB_config.widget_show_source&&a.source){b+=" "+TB_labels.from+" {6}"}b+="</span>";if(!TB_config.general_seo_tweets_googleoff&&TB_config.general_seo_footer_googleoff){b+="<!--googleon: index-->"}if(TB_config.widget_show_follow_link||TB_config.widget_show_reply_link){b+='<div class="tweet-tools" style="display:none;">';if(TB_config.widget_show_reply_link){b+='<a rel="nofollow" href="http://twitter.com/home?status=@{1}%20&in_reply_to_status_id={4}&in_reply_to={1}">'+TB_labels.reply+"</a>"}if(TB_config.widget_show_follow_link&&TB_config.widget_show_reply_link){b+=" | "}if(TB_config.widget_show_follow_link){b+='<a rel="nofollow" href="http://twitter.com/{1}">'+TB_labels.follow+" {1}</a>"}b+="</div>"}b+="</div>\n"}getDivId=function(c,d,e){return"t-"+c.getTime()+"-"+d+"-"+e};this.divId=getDivId(this.tweetDate,this.screenName,this.id);this.getHTML=function(){var g=this.jsonCode.text,f,e="",d="",c="";if(typeof(TB_sourceNames[this.screenName.toLowerCase()])!="undefined"){f=TB_sourceNames[this.screenName.toLowerCase()]}else{f=this.screenName}if(TB_config.general_link_urls){g=g.replace(/(https?:\/\/\S+)/gi,'<a rel="nofollow" href="$1">$1</a>')}if(TB_config.general_link_screen_names){g=g.replace(/\@([\w]+)/gi,'<a rel="nofollow" href="http://twitter.com/$1">@$1</a>')}if(TB_config.general_link_hash_tags){g=g.replace(/\#(\S+)/gi,'<a rel="nofollow" href="http://search.twitter.com/search?q=%23$1">#$1</a>')}if(a.profile_image_url){e=a.profile_image_url}else{e=a.user.profile_image_url}if(TB_config.general_timestamp_format){if(typeof(jQuery.PHPDate)!="undefined"){d+=jQuery.PHPDate(TB_config.general_timestamp_format,this.tweetDate)}else{if(typeof(jQnc.PHPDate)!="undefined"){d+=jQnc.PHPDate(TB_config.general_timestamp_format,this.tweetDate)}}}else{d+=TB_verbalTime(this.tweetDate)}if(a.source.indexOf("&lt;")>=0){c+=jQuery("<textarea/>").html(a.source).val()}else{c+=a.source}return b.format(this.divId,f,e,g,a.id_str,d,c)};this.isNewerThan=function(f){var g,e,d,c;if(typeof(f)=="undefined"){return true}else{if(f.indexOf("-")<=0){return true}else{g=f.split("-");d=g[1];c=g[2];e=this.tweetDate.getTime()}}if(e>d){return true}else{if(e<d){return false}else{if(this.screenName!=c){return true}else{return false}}}};this.isOlderThan=function(c){return !this.isNewerThan(c)};this.isSameId=function(d){var c,e;if(typeof(d)=="undefined"){return false}else{if(d.indexOf("-")<=0){return flase}else{c=d.split("-");e=this.divId.split("-");if(c.length==3||e.length==3){return(c[1]==e[1]&&c[2]==e[2])}else{return(c[1]==e[1]&&c[2]==e[2]&&c[3]==e[3])}}}};this.isOKtoShow=function(){var c;if(this.modifier){if(this.modifier.length>0&&this.jsonCode.text.indexOf(this.modifier)<0){return false}}if(TB_config.filter_hide_same_text){if(jQuery.inArray(this.jsonCode.text,TB_seenTweets)>0){return false}}if(this.jsonCode.in_reply_to_user_id||this.jsonCode.to_user_id){if(TB_config.filter_hide_replies){return false}}else{if(TB_config.filter_hide_not_replies){return false}}if(typeof(TB_config.filter_bad_strings)!="undefined"&&TB_config.filter_bad_strings.length>0){badStrings=TB_config.filter_bad_strings.base64_decode().split(",");for(c=0;c<badStrings.length;c++){if(this.jsonCode.text.indexOf(badStrings[c])>=0||this.screenName.indexOf(badStrings[c])>=0){return false}}}if(TB_config.filter_limit_per_source>0){if(typeof(TB_sourceCounts[this.screenName])!="undefined"||TB_sourceCounts[this.screenName]==0){if(TB_sourceCounts[this.screenName]>=TB_config.filter_limit_per_source){return false}else{TB_sourceCounts[this.screenName]++}}else{TB_sourceCounts[this.screenName]=1;if(TB_config.widget_limit_per_source_time>0){setTimeout('TB_sourceCounts["'+this.screenName+'"]=0',TB_config.widget_limit_per_source_time*1000)}}}return true}}TB_addLoadEvent(TB_start);jQuery(document).ready(TB_start); 
  • tweet-blender/trunk/lib/lib.php

    r406596 r427446  
    285285    'reply' => __('reply', 'tweetblender'), 
    286286    'follow' => __('follow', 'tweetblender'), 
    287     'limit_reset' => __('Next reset','tweetblender') 
     287    'limit_reset' => __('Next reset','tweetblender'), 
     288    'view_more' => __('view more','tweetblender')  
    288289); 
    289290 
  • tweet-blender/trunk/readme.txt

    r413340 r427446  
    44Requires at least: 2.8.0 
    55Tested up to: 3.2.1 
    6 Stable tag: 3.3.14 
     6Stable tag: 3.3.15 
    77Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=5907095 
    88 
     
    101101&lt;input type="hidden" name="tweetsNum" value="4" /> 
    102102&lt;input type="hidden" name="viewMoreUrl" value="http://twitter.com/tweetblender" /> 
     103&lt;input type="hidden" name="viewMoreText" value="Follow Us!" /> 
    103104</div&gt;</form&gt;` 
    104105 
     
    116117    'refresh_rate' => 60, 
    117118    'tweets_num' => 5, 
    118     'view_more_url' => 'http://twitter.com/tweetblender' 
     119    'view_more_url' => 'http://twitter.com/tweetblender', 
     120    'view_more_text' => 'follow us!' 
    119121));` 
    120122 
     
    184186 
    185187== Changelog == 
     188 
     189= 3.3.15 = 
     190* Bug fix: made "view more" link appear again (thanks to Somino for reporting via GetSatisfaction) 
     191* Improvement: both PHP tag and form embed now support view more text config option - see Installation tab (thanks to jenkins2541 for requesting via GetSatisfaction) 
     192* Improvement: faster page loads because JavaScript now loads in the footer (thanks to Alexander P for suggesting via GetSatisfaction) 
     193* Improvement: main.js is now minifiable (thanks to Martin E for requesting the fix via GetSatisfaction) 
    186194 
    187195= 3.3.14 = 
  • tweet-blender/trunk/tweet-blender.php

    r413340 r427446  
    44Plugin URI: http://www.tweetblender.com 
    55Description: Provides several Twitter widgets: show your own tweets, show tweets relevant to post's tags, show tweets for Twitter lists, show tweets for hashtags, show tweets for keyword searches, show favorite tweets. Multiple widgets on the same page are supported. Can combine sources and blend all of them into a single stream. 
    6 Version: 3.3.14 
     6Version: 3.3.15 
    77Author: Kirill Novitchenko 
    88Author URI: http://kirill-novitchenko.com 
     
    201201    // load PHPDate only if have a custom date 
    202202    if (isset($tb_o['general_timestamp_format']) && ($tb_o['general_timestamp_format'] != '')) { 
    203         wp_enqueue_script('phpdate', '/' . PLUGINDIR . '/tweet-blender/js/jquery.phpdate.js', array('jquery')); 
     203        wp_enqueue_script('phpdate', '/' . PLUGINDIR . '/tweet-blender/js/jquery.phpdate.js', array('jquery'), false, true); 
    204204        $dependencies[] = 'phpdate'; 
    205205    } 
    206206    // load JSON plugin only if caching is enabled 
    207207    if (isset($tb_o['advanced_disable_cache']) && ($tb_o['advanced_disable_cache'] != 'on')) { 
    208         wp_enqueue_script('tojson', '/' . PLUGINDIR . '/tweet-blender/js/jquery.json-2.2.min.js', array('jquery')); 
     208        wp_enqueue_script('tojson', '/' . PLUGINDIR . '/tweet-blender/js/jquery.json-2.2.min.js', array('jquery'), false, true); 
    209209        $dependencies[] = 'tojson'; 
    210210    } 
    211211     
    212212    // load jsonp plugin with good error hanlding 
    213     wp_enqueue_script('jsonp', '/' . PLUGINDIR . '/tweet-blender/js/jquery.jsonp-2.1.4.min.js', array('jquery')); 
     213    wp_enqueue_script('jsonp', '/' . PLUGINDIR . '/tweet-blender/js/jquery.jsonp-2.1.4.min.js', array('jquery'), false, true); 
    214214     
    215215    // load lib 
    216     wp_enqueue_script('tb-lib', '/' . PLUGINDIR . '/tweet-blender/js/lib.js',array('jquery')); 
     216    wp_enqueue_script('tb-lib', '/' . PLUGINDIR . '/tweet-blender/js/lib.js',array('jquery'), false, true); 
    217217    wp_localize_script('tb-lib', 'TB_labels', $js_labels); 
    218218    $dependencies[] = 'tb-lib'; 
    219219     
    220220    // load main JS code 
    221     wp_enqueue_script('tb-main', '/' . PLUGINDIR . '/tweet-blender/js/main.js', $dependencies); 
     221    wp_enqueue_script('tb-main', '/' . PLUGINDIR . '/tweet-blender/js/main.js', $dependencies, false, true); 
    222222} 
    223223 
     
    272272    'refresh_rate'=> 60, 
    273273    'tweets_num' => 5, 
    274     'view_more_url' => 'http://twitter.com/tweetblender' 
     274    'view_more_url' => 'http://twitter.com/tweetblender', 
     275    'view_more_text' => 'follow us!' 
    275276));</pre>";  
    276277    } 
     
    283284            'widget_refresh_rate' => $options['refresh_rate'], 
    284285            'widget_tweets_num' => $options['tweets_num'], 
    285             'widget_view_more_url' => $options['view_more_url'] 
     286            'widget_view_more_url' => $options['view_more_url'], 
     287            'widget_view_more_text' => $options['view_more_text'] 
    286288        )); 
    287289    } 
     
    289291} 
    290292 
    291 // template tag for general widget 
     293// template tag for general tags widget 
    292294function tweet_blender_widget_for_tags($options) { 
    293295 
  • tweet-blender/trunk/widget-favorites.php

    r381114 r427446  
    11<?php 
    22 
    3 // version 3.3.6 
     3// version 3.3.15 
    44 
    55class TweetBlenderFavorites extends WP_Widget { 
     
    6767 
    6868            echo '<div class="tb_footer">'; 
    69             if(!$tb_o['archive_is_disabled']) { 
     69            if(!$tb_o['archive_is_disabled'] || $tb_o['archive_is_disabled'] == false) { 
    7070                 
    7171                // indicate that using default url 
  • tweet-blender/trunk/widget.php

    r405242 r427446  
    11<?php 
    22 
    3 // version 3.3.10 
     3// version 3.3.15 
    44 
    55class TweetBlender extends WP_Widget { 
     
    6969             
    7070            echo '<div class="tb_footer">'; 
    71             if(!isset($tb_o['archive_is_disabled'])) { 
     71            if(!isset($tb_o['archive_is_disabled']) || $tb_o['archive_is_disabled'] == false) { 
    7272                 
    7373                // indicate that using default url 
  • tweet-blender/trunk/ws.php

    r381114 r427446  
    11<?php 
    22 
    3 // version 3.3.6 
     3// version 3.3.15 
    44 
    55// include WP functions 
     
    7575 
    7676    // check if it's a private source or if we are rerouting with oAuth 
    77     if (isset($_GET['private']) || ($tb_o['advanced_reroute_on'] && $tb_o['advanced_reroute_type'] == 'oauth')) { 
     77    if (isset($_GET['is_private']) || ($tb_o['advanced_reroute_on'] && $tb_o['advanced_reroute_type'] == 'oauth')) { 
    7878         
    7979        // check to make sure we have the class 
Note: See TracChangeset for help on using the changeset viewer.