/***********************************************

   FILE:  JavaScript/humor/priswork.js
   AUTH:  Thuy Le
   Date:  September 28, 2000
   LMD :  March 6, 2009

	Prison vs Work

***********************************************/

currPrisonWork = 1
maxPrisonWork = 11
prisonWorkText = ""
pw = new Array()
pwi = new Array()

for ( i=1; i<= maxPrisonWork; i++ )
{
	pwi[i] = new Image()
	pwi[i].src = "../../images/fun/pw/image0" + i + ".gif"
}

for ( i=0 ; i<=maxPrisonWork ; i++ ) pw[i] = ""

pw[1] += "IN PRISON... you spend the majority of your time in an 8X10 cell;\n\n"
pw[1] += "AT WORK... you spend the majority of your time in a 6X8 cubicle."

pw[2] += "IN PRISON... you get three meals a day;\n\n"
pw[2] += "AT WORK... you only get a break for one meal and you have to pay\n"
pw[2] += "for it."

pw[3] += "IN PRISON... you get time off for good behavior;\n\n"
pw[3] += "AT WORK... you get rewarded for good behavior with more work."

pw[4] += "IN PRISON... the guard locks and unlocks all the doors for you;\n\n"
pw[4] += "AT WORK... you must carry around a security card and open all the\n"
pw[4] += "doors for yourself."

pw[5] += "IN PRISON... you can watch TV and play games;\n\n"
pw[5] += "AT WORK... you get fired for watching TV and playing games."

pw[6] += "IN PRISON... you get your own toilet;\n\n"
pw[6] += "AT WORK... you have to share."

pw[7] += "IN PRISON... they allow your family and friends to visit;\n\n"
pw[7] += "AT WORK... you can't even speak to your family."

pw[8] += "IN PRISON... all expenses are paid by the tax-payers with no\n"
pw[8] += "work required;\n\n"
pw[8] += "AT WORK... you get to pay all the expenses to go to work and\n"
pw[8] += "then they deduct taxes from your salary to pay for prisoners."

pw[9] += "IN PRISON... you spend most of your life looking through bars\n"
pw[9] += "from inside wanting to get out.\n\n"
pw[9] += "AT WORK... you spend most of your time wanting to get out and go\n"
pw[9] += "inside bars."

pw[10] += "IN PRISON... there are wardens.\n\n"
pw[10] += "AT WORK... they are called managers."

pw[11] += "But cheer up, because\n\n"
pw[11] += "IN PRISON... you have to stay in all the time.\n\n"
pw[11] += "AT WORK... you get to go home sometimes."


function prev_pw() {
	if ( currPrisonWork==1 ) 
		currPrisonWork = maxPrisonWork
	else
		currPrisonWork--
	display_pw()
}

function next_pw() {
	if ( currPrisonWork == maxPrisonWork ) 
		currPrisonWork = 1
	else
		currPrisonWork++
	display_pw()
}

function display_pw() {
	document.PrisonWork.prisonWork.value = pw[currPrisonWork]
	pw_img()
}

function pw_img() {
	if ( currPrisonWork <= maxPrisonWork )
		switchPWI(currPrisonWork)
	else
		switchPWI(1)
}

function switchPWI(currImg) {
	document.images[3].src = eval("pwi["+currImg+"].src")
}







