		//<!--
		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', '10px');
						}
						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 : 50;
							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;

						$strip.css("left", 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(cobj_newst_cat) != 'undefined' && cobj_newst_cat) {
				ONAPI.request({
					data:{module:'blog', action:'news_ticker', user_id:userId, category_id:cobj_newst_cat, page_id:cobj_news_pageid, max:cobj_newst_count},
					callback:function(data) {
						if(jQ('#newst_wrapper > .tickercontainer').length) {
							var contents = jQ('#newst_wrapper').children('.tickercontainer').children('.mask').contents();
							jQ('#newst_wrapper').children('.tickercontainer').before(contents).remove();
						}
						if(jQ('#newst_wrapper').not(':visible')) {
							jQ('#newst_wrapper').fadeIn(800);
						}
						if(isNaN(parseFloat(cobj_newst_travelocity))) {
							cobj_newst_travelocity = 0.07;
						}
						jQ('#newst_wrapper').find("ul#ticker02").empty().append(data).liScroll({
							travelocity: cobj_newst_travelocity
						});						
					},
					error:function(data) {
						//alert(data.error_message);
					}
				});
	
			} else {
				// no username here
				jQ('#newst_wrapper').fadeIn(300);
			}
		});
		//-->
