function Notification () {
	/**
	* Set some variables to the post.
	*/
	this.urlMoreNotifications	= "ajax/member_get_notifications.php";
	this.urlGetSLNotifications	= "ajax/member_get_slnotifications.php";
	this.offset					= 10;
	this.slNotificationsCache 	= false;
	this.status					= 'close';
	
	this.getNotifications = function () {
		$("#notificationLoading").toggle();
		var me = this;	
		$.ajax({
			type: "POST",
			dataType: "json",
			url: this.urlMoreNotifications,
			async: true,
			data: ({ offset : this.offset }),	
			success: function(data){
				if ( data.result == "done") {
					var html = "";
					
					// Create the items container
					html = '<div id="more_'+me.offset+'" style="display:none;">'+ data.html +'</div>';
					
					// Show the stories
					$("div[id^='notification_']:last").after(html);
					$("#more_"+me.offset).fadeIn(1500);
					
					// Recalculate the offset and lesftsStories
					leftStories = leftStories - 10;
					me.offset = me.offset + 10;
					if (leftStories <= 0) {
						$(".notification_footer").children().html("");
					}
					
					$("#storiesLeft").html(leftStories); 
	
				} else {
					alert(data.result);
				}
				$("#notificationLoading").toggle();
			}
		});		
	}

	this.getSLNotifications = function(){
		$("#slNotificationTab").toggleClass('open');
		$("#slNotificationTab").toggleClass('close');
		
		if (pm.status == 'open'){ 
			$("#MailNotificationContent").hide();
			$("#MailNotificationTab").removeClass('open');
			$("#MailNotificationTab").addClass('close');
			pm.status = 'close';
		}
		
		if (this.status == 'close'){
			$("#slNotificationContent").show();
			this.status = 'open';
			if (this.slNotificationsCache == false){
				this.slNotificationsCache = true;
				$.ajax({
					type: "POST",
					dataType: "json",
					url: this.urlGetSLNotifications,
					async: true,
					success: function(data){
						if ( data.result == "done") {
							$("#slNotificationContent").html(data.html);
							$("#slNotificationTab").html('<img src="images/system/minialert_notif_off_16x16.png" width="16" height="16" />');
						} else {
							alert(data.result);
						}
					}
				});	
			}
		}else{
			$("#slNotificationContent").hide();
			this.status = 'close';
		}
	}
}

	