		//<!--
		jQuery.fn.liScroll = function(settings) {
				settings = jQuery.extend({
				travelocity: 0.07
				}, settings);		
				return this.each(function(){
						var $strip = jQuery(this);
						$strip.addClass("newsticker");
						var stripWidth = 0;
						var $mask = $strip.wrap("<div class='mask'></div>");
						if(jQuery.browser.msie && jQuery.browser.version < 7) {
							$strip.parent('.mask').css('top', '12px');
						}
						var $tickercontainer = $strip.parent().wrap("<div class='tickercontainer'></div>");
						var containerWidth = $strip.parent().parent().width();	//a.k.a. 'mask' width 	
						$strip.find("li").each(function(i){
							var buffer = (jQuery.browser.msie && jQuery.browser.version < 7) ? 120 : 220;
							var width = jQuery(this, i).width();
							stripWidth += width + buffer;
						});
						$strip.width(stripWidth);
						stripWidth = 0;
						// this is kinda ghetto but there is no way to get an accurate width without it already floating
						$strip.find("li").each(function(i){
							var buffer = (jQuery.browser.msie && jQuery.browser.version < 7) ? 185 : 5;
							var width = jQuery(this, i).outerWidth(true);
							if(jQuery(this,i).find('a').length && (jQuery.browser.msie && jQuery.browser.version < 7)) {
								var a_width = 0;
								jQuery(this,i).find('a').each(function(){
									a_width = jQuery(this).outerWidth(true);
								});
								width += a_width;
							}
							stripWidth += width + buffer;
						});
						$strip.width(stripWidth);					
						var defTiming = stripWidth/settings.travelocity;
						var totalTravel = stripWidth+containerWidth;								
						function scrollnews(spazio, tempo){
							$strip.animate(
											{left: '-='+ spazio},
											tempo, 
											"linear", 
											function(){
												$strip.css("left", containerWidth);
												scrollnews(totalTravel, defTiming);
											}
										);
						}
						scrollnews(totalTravel, defTiming);				
							$strip.hover(function(){
						jQuery(this).stop();
						},
						function(){
						var offset = jQuery(this).offset();
						var residualSpace = offset.left + stripWidth;
						var residualTime = residualSpace/settings.travelocity;
						scrollnews(residualSpace, residualTime);
						});			
				});	
		};
		/* DOM Ready!! */
		jQ(function(){
		    if (typeof(twt_username) != 'undefined' && twt_username) {
				jQ('#twt_wrapper > .ticker_img').wrap('<a href="http://twitter.com/'+twt_username+'"></a>'); // wrap img with twitter link
				if(jQ('#twt_wrapper').find('#ticker01').length) {
					var twt_ul = jQ('#twt_wrapper').find('ul#ticker01');
				} else {
					var twt_ul = jQ('#twt_wrapper').contents().find('ul#ticker01');
				}
				ONAPI.request({
					data:{module:"twitter", action:"get", user_id:userId, username:twt_username, count:twt_count, wrap:"li", elem:"twitter_post", caps:1},
					callback:function(data) {
						twt_ul.empty().append(data);
						if(jQ('#twt_wrapper > .tickercontainer').length) {
							var contents = jQ('#twt_wrapper').children('.tickercontainer').children('.mask').contents();
							jQ('#twt_wrapper').children('.tickercontainer').before(contents).remove();
						}
						if(jQ('#twt_wrapper').not(':visible')) {
							jQ('#twt_wrapper').fadeIn(800);
						}
						if(isNaN(parseFloat(twt_travelocity))) {
							twt_travelocity = 0.07;
						}
						
						twt_ul.css('left', '0px').liScroll({
							travelocity: twt_travelocity
						});
					},
					error:function(data) {
						//alert(data.error_message);
					}
				});
				/*				
				twt_ul.empty().twitterize(twt_username, {
					count: twt_count,
					wrap: 'li',
					elem: 'twitter_post',
					callback: function(){
						if(jQ('#twt_wrapper > .tickercontainer').length) {
							var contents = jQ('#twt_wrapper').children('.tickercontainer').children('.mask').contents();
							jQ('#twt_wrapper').children('.tickercontainer').before(contents).remove();
						}
						if(jQ('#twt_wrapper').not(':visible')) {
							jQ('#twt_wrapper').fadeIn(800);
						}
						if(isNaN(parseFloat(twt_travelocity))) {
							twt_travelocity = 0.07;
						}
						
						twt_ul.css('left', '0px').liScroll({
							travelocity: twt_travelocity
						});
						
					}
				}); // end of twitterize
				*/
			} else {
				jQ('#twt_wrapper').fadeIn(300);
			}
		});
		//-->
