function dataHandler() {
	var currentStepNumber;
	var stepIsValid;
	
	this.init = function() {
		if(!$.cookies.test()) {
			alert('The Browser Cookies should be activated');
			return false; 
		}
		this.setValue('currentStep','1');//407
		this.currentStepNumber = this.getValue('currentStep');
		
	
		if(!this.currentStepNumber || this.currentStepNumber == null) {
			this.currentStepNumber = '1';
			this.setValue('currentStep',this.currentStepNumber);
			this.setValue('stepCompleted','false');
			this.stepIsValid = false;
		}
	};
	
	/*** GET DATA FROM THE COOKIES ***/
	this.getValue = function( varname ) {
		if(varname == 'currentStep') {
			return $.cookies.get(varname);
		} else {
			var stepInfo = $.cookies.get(this.currentStepNumber+'StepData');
			var returnValue = null;
			if(stepInfo != null) {
				stepInfo = $.evalJSON(stepInfo);
				if(stepInfo[varname] != undefined) {
					returnValue = stepInfo[varname];
				} else {
					returnValue = null;
				}
			}
			return returnValue;
		}	
	};
	
	/**
	 * - SET DATA ON THE COOKIES
	 * Set value on the currentStepData JSON object variable, 
	 * if the cookie for the current step doesn't exists it create one and add the variable
	 */
	this.setValue = function( varname , value ) {
		if(varname == 'currentStep') {
			$.cookies.set(varname,value);
		} else {
			var stepInfo = $.cookies.get(this.currentStepNumber+'StepData');
			if(!stepInfo || stepInfo == null) {
				stepInfo = '{"'+varname+'":"'+value+'"}';
				$.cookies.set(this.currentStepNumber+'StepData',stepInfo);
			} else {
				stepInfo = $.evalJSON(stepInfo);
				stepInfo[varname] = value.toString();
				stepInfo = $.toJSON(stepInfo);
				$.cookies.set(this.currentStepNumber+'StepData',stepInfo);			
			}
		}
		
		return true;
	}		
}