code: function (val) {
  		var parseDate = this.options.parseDate,
  			ret,
  			key,
  			format,
  			dateFormat = this.options.dateFormat || this.dateFormat,
  			match;
  
  		if (parseDate) {
  			ret = parseDate(val);
  		
  		} else if (typeof val === 'string') {
  			// Auto-detect the date format the first time
  			if (!dateFormat) {
  				for (key in this.dateFormats) {
  					format = this.dateFormats[key];
  					match = val.match(format.regex);
  					if (match) {
  						this.dateFormat = dateFormat = key;
  						this.alternativeFormat = format.alternative;
  						ret = format.parser(match);
  						break;
  					}
  				}
  			// Next time, use the one previously found
  			} else {
  				format = this.dateFormats[dateFormat];
  				match = val.match(format.regex);
  				if (match) {
  					ret = format.parser(match);
  				}
  			}
  			// Fall back to Date.parse		
  			if (!match) {
  				match = Date.parse(val);
  				// External tools like Date.js and MooTools extend Date object and
  				// returns a date.
  				if (typeof match === 'object' && match !== null && match.getTime) {
  					ret = match.getTime() - match.getTimezoneOffset() * 60000;
  				
  				// Timestamp
  				} else if (typeof match === 'number' && !isNaN(match)) {
  					ret = match - (new Date(match)).getTimezoneOffset() * 60000;
  				}
  			}
  		}
  		return ret;
  	}
docs: Parse a date and return it as a number. Overridable through options.parseDate.