<?php
header('Content-type: text/javascript');
$old_path = getcwd();
chdir('../../../../../');
define( '_JEXEC', 1 );
define('JPATH_BASE', getcwd() );
define( 'DS', DIRECTORY_SEPARATOR );
require_once("configuration.php");
require_once ( JPATH_BASE .DS.'includes'.DS.'defines.php' );
require_once ( JPATH_BASE .DS.'includes'.DS.'framework.php' );
$mainframe =& JFactory::getApplication('site');
$mainframe->initialise();
$lang =& JFactory::getLanguage();
//$lang->setLanguage(JRequest::getVar('lang','en-GB'));
$lang->load('com_dtregister');

//$lang =& JFactory::getLanguage();
//chdir($old_path);
?> 
var i18n = DTjQuery.extend({}, i18n || {}, {

    xgcalendar: {

        dateformat: {

            "fulldaykey": "MMddyyyy",

            "fulldayshow": "L d yyyy",

            "fulldayvalue": "M/d/yyyy",

            "Md": "W M/d",

            "Md3": "L d",

            "separator": "/",

            "year_index": 2,

            "month_index": 0,

            "day_index": 1,

            "day": "d",

            "sun": "<?php echo JText::_('DT_SUN')?>",

            "mon": "<?php echo JText::_('DT_MON')?>",

            "tue": "<?php echo JText::_('DT_TUE')?>",

            "wed": "<?php echo JText::_('DT_WED')?>",

            "thu": "<?php echo JText::_('DT_THU')?>",

            "fri": "<?php echo JText::_('DT_FRI')?>",

            "sat": "<?php echo JText::_('DT_SAT')?>",

            "jan": "<?php echo JText::_('DT_JAN')?>",

            "feb": "<?php echo JText::_('DT_FEB')?>",

            "mar": "<?php echo JText::_('DT_MAR')?>",

            "apr": "<?php echo JText::_('DT_APR')?>",

            "may": "<?php echo JText::_('DT_MAY')?>",

            "jun": "<?php echo JText::_('DT_JUN')?>",

            "jul": "<?php echo JText::_('DT_JUL')?>",

            "aug": "<?php echo JText::_('DT_AUG')?>",

            "sep": "<?php echo JText::_('DT_SEP')?>",

            "oct": "<?php echo JText::_('DT_OCT')?>",

            "nov": "<?php echo JText::_('DT_NOV')?>",

            "dec": "<?php echo JText::_('DT_DEC')?>",
            
            "janfull": "<?php echo JText::_('DT_JAN_FULL')?>",

            "febfull": "<?php echo JText::_('DT_FEB_FULL')?>",

            "marfull": "<?php echo JText::_('DT_MAR_FULL')?>",

            "aprfull": "<?php echo JText::_('DT_APR_FULL')?>",

            "mayfull": "<?php echo JText::_('DT_MAY_FULL')?>",

            "junfull": "<?php echo JText::_('DT_JUN_FULL')?>",

            "julfull": "<?php echo JText::_('DT_JUL_FULL')?>",

            "augfull": "<?php echo JText::_('DT_AUG_FULL')?>",

            "sepfull": "<?php echo JText::_('DT_SEP_FULL')?>",

            "octfull": "<?php echo JText::_('DT_OCT_FULL')?>",

            "novfull": "<?php echo JText::_('DT_NOV_FULL')?>",

            "decfull": "<?php echo JText::_('DT_DEC_FULL')?>"
            
            

        },

        "no_implemented": "<?php echo JText::_('DT_NO_IMPLEMENT')?>",

        "to_date_view": "<?php echo JText::_('DT_CLICK_VIEW_CURRENT_DATE')?>",

        "i_undefined": "<?php echo JText::_('DT_UNDEFINED')?>",

        "allday_event": "<?php echo JText::_('DT_ALL_DAY_EVENT')?>",

        "repeat_event": "<?php echo JText::_('DT_REPEAT_EVENT')?>",

        "time": "<?php echo JText::_('DT_TIME')?>",

        "event": "<?php echo JText::_('DT_EVENT')?>",

        "location": "<?php echo JText::_('DT_LOCATION')?>",

        "participant": "<?php echo JText::_('DT_PARTICIPANT')?>",

        "get_data_exception": "<?php echo JText::_('DT_DATA_EXCEPTION')?>",

        "new_event": "<?php echo JText::_('DT_NEW_EVENT')?>",

        "confirm_delete_event": "<?php echo JText::_('DT_CONFIRM_DELETE')?> ",

        "confrim_delete_event_or_all": "<?php echo JText::_('DT_DELETE_EVENT_ALL')?>",

        "data_format_error": "<?php echo JText::_('DT_DATE_ERROR')?>",

        "invalid_title": "<?php echo JText::_('DT_EVENT_TITLE_BLANK')?>",

        "view_no_ready": "<?php echo JText::_('DT_VIEW_NOT_READY')?>",

        "example": "<?php echo JText::_('DT_EXAMPLE')?>",

        "content": "<?php echo JText::_('DT_WHAT')?>",

        "create_event": "<?php echo JText::_('DT_CREATE_EVENT')?>",

        "update_detail": "<?php echo JText::_('DT_EDIT_DETAILS')?>",

        "click_to_detail": "<?php echo JText::_('DT_VIEW_DETAILS')?>",

        "i_delete": "<?php echo JText::_('DT_DELETE')?>",

        "day_plural": "<?php echo JText::_('DT_DAYS')?>",

        "others": "<?php echo JText::_('DT_OTHERS')?>",
        "more": "<?php echo JText::_('DT_MORE')?>",
        "see": "<?php echo JText::_('DT_SEE')?>",
        "item": ""

    }

});
var dateformat = function () {
	var	token = /d{1,4}|m{1,4}|yy(?:yy)?|([HhMsTt])\1?|[LloSZ]|"[^"]*"|'[^']*'/g,
		timezone = /\b(?:[PMCEA][SDP]T|(?:Pacific|Mountain|Central|Eastern|Atlantic) (?:Standard|Daylight|Prevailing) Time|(?:GMT|UTC)(?:[-+]\d{4})?)\b/g,
		timezoneClip = /[^-+\dA-Z]/g,
		pad = function (val, len) {
			val = String(val);
			len = len || 2;
			while (val.length < len) val = "0" + val;
			return val;
		};

	// Regexes and supporting functions are cached through closure
	return function (date, mask, utc) {
		var dF = dateformat;

		// You can't provide utc if you skip other args (use the "UTC:" mask prefix)
		if (arguments.length == 1 && Object.prototype.toString.call(date) == "[object String]" && !/\d/.test(date)) {
			mask = date;
			date = undefined;
		}

		// Passing date through Date applies Date.parse, if necessary
		date = date ? new Date(date) : new Date;
		if (isNaN(date)) throw SyntaxError("invalid date");

		mask = String(dF.masks[mask] || mask || dF.masks["default"]);

		// Allow setting the utc argument via the mask
		if (mask.slice(0, 4) == "UTC:") {
			mask = mask.slice(4);
			utc = true;
		}

		var	_ = utc ? "getUTC" : "get",
			d = date[_ + "Date"](),
			D = date[_ + "Day"](),
			m = date[_ + "Month"](),
			y = date[_ + "FullYear"](),
			H = date[_ + "Hours"](),
			M = date[_ + "Minutes"](),
			s = date[_ + "Seconds"](),
			L = date[_ + "Milliseconds"](),
			o = utc ? 0 : date.getTimezoneOffset(),
			flags = {
				d:    d,
				dd:   pad(d),
				ddd:  dF.i18n.dayNames[D],
				dddd: dF.i18n.dayNames[D + 7],
				m:    m + 1,
				mm:   pad(m + 1),
				mmm:  dF.i18n.monthNames[m],
				mmmm: dF.i18n.monthNames[m + 12],
				yy:   String(y).slice(2),
				yyyy: y,
				h:    H % 12 || 12,
				hh:   pad(H % 12 || 12),
				H:    H,
				HH:   pad(H),
				M:    M,
				MM:   pad(M),
				s:    s,
				ss:   pad(s),
				l:    pad(L, 3),
				L:    pad(L > 99 ? Math.round(L / 10) : L),
				t:    H < 12 ? "a"  : "p",
				tt:   H < 12 ? "am" : "pm",
				T:    H < 12 ? "A"  : "P",
				TT:   H < 12 ? "AM" : "PM",
				Z:    utc ? "UTC" : (String(date).match(timezone) || [""]).pop().replace(timezoneClip, ""),
				o:    (o > 0 ? "-" : "+") + pad(Math.floor(Math.abs(o) / 60) * 100 + Math.abs(o) % 60, 4),
				S:    ["th", "st", "nd", "rd"][d % 10 > 3 ? 0 : (d % 100 - d % 10 != 10) * d % 10]
			};

		return mask.replace(token, function ($0) {
			return $0 in flags ? flags[$0] : $0.slice(1, $0.length - 1);
		});
	};
}();
// Internationalization strings
dateformat.i18n = {
	dayNames: [
		"<?php echo JText::_('DT_SUN')?>", "<?php echo JText::_('DT_MON')?>", "<?php echo JText::_('DT_TUE')?>", "<?php echo JText::_('DT_WED')?>", "<?php echo JText::_('DT_THU')?>", "<?php echo JText::_('DT_FRI')?>", "<?php echo JText::_('DT_SAT')?>",
		"<?php echo JText::_('DT_SUN')?>", "<?php echo JText::_('DT_MON')?>", "<?php echo JText::_('DT_TUE')?>", "<?php echo JText::_('DT_WED')?>", "<?php echo JText::_('DT_THU')?>", "<?php echo JText::_('DT_FRI')?>", "<?php echo JText::_('DT_SAT')?>"
	],
	monthNames: [
		"<?php echo JText::_('DT_JAN')?>", "<?php echo JText::_('DT_FEB')?>", "<?php echo JText::_('DT_MAR')?>", "<?php echo JText::_('DT_APR')?>", "<?php echo JText::_('DT_MAY')?>", "<?php echo JText::_('DT_JUN')?>", "<?php echo JText::_('DT_JUL')?>", "<?php echo JText::_('DT_AUG')?>", "<?php echo JText::_('DT_SEP')?>", "<?php echo JText::_('DT_OCT')?>", "<?php echo JText::_('DT_NOV')?>", "<?php echo JText::_('DT_DEC')?>",
		"<?php echo JText::_('DT_JAN_FULL')?>", "<?php echo JText::_('DT_FEB_FULL')?>", "<?php echo JText::_('DT_MAR_FULL')?>", "<?php echo JText::_('DT_APR_FULL')?>", "<?php echo JText::_('DT_MAY_FULL')?>", "<?php echo JText::_('DT_JUN_FULL')?>", "<?php echo JText::_('DT_JUL_FULL')?>", "<?php echo JText::_('DT_AUG_FULL')?>", "<?php echo JText::_('DT_SEP_FULL')?>", "<?php echo JText::_('DT_OCT_FULL')?>", "<?php echo JText::_('DT_NOV_FULL')?>", "<?php echo JText::_('DT_DEC_FULL')?>"
	]
};

