Tweet.js-Mod
Tweet.js-Mod copied to clipboard
Ticker Function
Hi Stan
Thanks for your mod script, I got this to work on my site, but the ticker functions I had working with the original tweet.js script, do not work with your updated script.
1.Ticker Function
Can you help with this getting the above functions to work again with your mod script?
Thanks Stan
Cheers Van
My js code in the twitter page
+1 for wtadesign
your script worked great! very good job. if the ticker could also work it would have been perfect!
COPY/PASTE SECTION FROM TWEET.SEAOFCLOUDS.COM #11:
#11 - display one tweet at a time like a ticker: jQuery(function($){ $("#ticker").tweet({ username: "seaofclouds", page: 1, avatar_size: 32, count: 20, loading_text: "loading ..." }).bind("loaded", function() { var ul = $(this).find(".tweet_list"); var ticker = function() { setTimeout(function() { var top = ul.position().top; var h = ul.height(); var incr = (h / ul.children().length); var newTop = top - incr; if (h + newTop <= 0) newTop = 0; ul.animate( {top: newTop}, 500 ); ticker(); }, 5000); }; ticker(); }); });
Again, thank you!
I too have lost my tickers from V1. I'm truly a novice at scripting and can't seem to find a solution for this anywhere. It's only showing the last tweet. Any help is appreciated! thank you!
I separated the ticker function and have it load on document.ready. Ticker is working for me now.
jQuery(function($){ $(".hjtweet").tweet({ username: "harryjoshhair", page: 1, avatar_size: 48, count: 20, loading_text: "loading ..." }) });
$(document).ready(function() {
var ul = $(this).find(".tweet_list");
var ticker = function() {
setTimeout(function() {
var top = ul.position().top;
var h = ul.height();
var incr = (h / ul.children().length);
var newTop = top - incr;
if (h + newTop <= 0) newTop = 0;
ul.animate( {top: newTop}, 500 );
ticker();
}, 7000);
};
ticker();
});
Re: visufish
Thats great, thanks for working that out (works great now). I just added a // $('#ticker a').attr('target','_blank'); // to it, to force the links to open a new window.
thank you.
jQuery(function($){ $(".hjtweet").tweet({ username: "harryjoshhair", page: 1, avatar_size: 48, count: 20, loading_text: "loading ..." }) });
$(document).ready(function() {
var ul = $(this).find(".tweet_list"); var ticker = function() { setTimeout(function() { var top = ul.position().top; var h = ul.height(); var incr = (h / ul.children().length); var newTop = top - incr; if (h + newTop <= 0) newTop = 0; ul.animate( {top: newTop}, 500 ); ticker(); }, 7000); }; ticker(); $('#ticker a').attr('target','_blank'); });
Well done visufish and wtadesign. It works for me too!!!
Fantastic news that it is working for you! I am still struggling and not sure where to go from here. This is a test page displaying what I have and am grateful for any help or guidance!
(URL removed)
I'm using the modified jquery.tweet.js and your code above but it's still displaying the latest tweet only. It doesn't seem to be loading anything into #ticker so maybe the html is wrong?
Thank you again for any help!
try putting this nearer to the end of the closing body tag, your current order of scripts might have a conflict with your easy easySlider Js.
I went back and modified the script I had before by using load on ready function and voila! It works again. Thanks again for your help!
I've tried but can't see anything
if i use other examples it's work only the ticker not
you can find my source on
http://pastebin.com/xNygM8EG
Att: helmuteke Pleas check your path for src="./twitter/jquery.tweet.js I think it would be ../ if that is one folder up from your current twitter index page. and make sure that the "twitter" folder is in your root directory, not in a sub folder.
Have a look at http://pastebin.com/DbaW3tu2
Att: wtadesign
If i place you pastebin in index.html at root and twitter folder also
it doesn't work the ticker
Try making your ".hjtweet" to " #ticker"
and then copying these items
/* -- css ticker tweet version */
#ticker { height:26em; overflow-y: hidden; position: relative; padding: 0px 8px 10px 8px; margin: 0 0 3px 0;
}
#ticker ul.tweet_list {
position: absolute;
}
#ticker ul.tweet_list li {
height: 100%;
}
/* -- div id for ticker in your html page */
/* -- js include and function to go at the bottom of you html before
*/
now it works , tnx a lot