function ListLoader( url, listContainer, listElements, actionParams ) {
	
	this.actionParams = $j.extend( {
		offset : 0,
		limit : 5
	}, actionParams );
	
	this.url = url;
	this.listContainer = $j( listContainer );
	this.listElements = ( listElements || '.list_element')
	this.isListLoading = false;
	this.isAllListLoaded = false;
	
	this.loadNext = function( actionParams ) {
		if ( this.isListLoading || this.isAllListLoaded ) return false;
		var referenceToThis = this;
		var requestOptions = {
			url: url,
			type: 'GET',
			data: $j.extend( this.actionParams, actionParams ),
			success: function ( response ) {
				referenceToThis.isListLoading = false;
				var receivedElements = $j( referenceToThis.listElements, '<div>' + response + '</div>' );
				referenceToThis.actionParams['offset'] += receivedElements.length;
				if ( receivedElements.length < referenceToThis.actionParams['limit'] ) referenceToThis.isAllListLoaded = true;
				referenceToThis.listContainer.append( receivedElements );
				$j(".blog_item:odd").css("background-color", "#f1f1f1");
			}
		};
		this.isListLoading = true;
		$j.ajax( requestOptions );
	}
}

function listLoadCondition() {
	return ( $j( window ).scrollTop() == $j( document ).height() - $j( window ).height() );
}