// Panmedia Portfolio
AdvArray = new Array("guardian-cover.jpg", "guardian-april.jpg","jagas.jpg", "gogreen.jpg", "salon10.jpg", "citigroup11.jpg",  "scotia-directory.jpg", "guiness-1.jpg", "guiness-2.jpg", "guiness-3.jpg", "guiness-4.jpg", "adv_fgb-customer.jpg","yuh-proper.jpg", "adv_fgb2.jpg", "adv_fgb-liguanea.jpg", "adv_worlkskills.jpg", "adv_guardian-light.jpg", "MOH-Brochure2.jpg", "MOH-Poster2.jpg", "BC-Worry-Less.jpg", "CIB-Poster.jpg", "adv_round-hill.jpg", "adv_fiscal.jpg", "Kronos.jpg", "citibank-responsive3.jpg", "watt.jpg", "be-bright.jpg", "watt2.jpg", "be-bright2.jpg", "watt3.jpg", "be-bright3.jpg", "adv_44.jpg", "adv_32.jpg", "adv_33.jpg", "adv_34.jpg", "adv_35.jpg", "adv_36.jpg", "adv_38.jpg", "adv_39.jpg", "adv_40.jpg", "adv_43.jpg", "adv_31.jpg", "adv_45.jpg", "adv_46.jpg", "adv_48.jpg", "adv_05.jpg", "adv_03.jpg", "adv_04.jpg", "adv_07.jpg", "adv_02.jpg", "adv_09.jpg", "adv_10.jpg", "adv_11.jpg", "adv_12.jpg", "adv_13.jpg", "adv_14.jpg", "adv_15.jpg", "adv_16.jpg", "adv_17.jpg", "adv_18.jpg", "adv_19.jpg", "adv_20.jpg", "adv_21.jpg", "adv_22.jpg", "adv_23.jpg", "adv_24.jpg", "adv_25.jpg", "adv_26.jpg", "adv_27.jpg", "adv_28.jpg", "adv_29.jpg", "MOh-poster.jpg");

WebArray = new Array("gkms.jpg", "fxtrader.jpg","billexpress.jpg","westernunion.jpg", "guardianlife.jpg?cache=0","ivs.jpg", "nhp.jpg", "svghotels.jpg","vpaj.jpg", "nht.jpg","suss.jpg", "yuhrate.jpg", "scotia.jpg", "pollja.jpg", "web_cpj.jpg",  "web-voss.jpg", "web-blogja.jpg", "web-dbj.jpg", "web_itg.jpg", "web_itg-benz.jpg","itg-audi.jpg","itg-honda.jpg", "web-exim.jpg", "web-undp.jpg", "rtv.jpg", "agro.jpg", "hnl.jpg", "web_psoj.jpg", "web_taboo.jpg", "web_coralcay.jpg", "gracefoods.jpg", "isa.jpg", "web_millpress.jpg", "go4less.jpg", "sseja.jpg", "hawkeye.jpg", "emc.jpg", "web_emcvpa.jpg", "web-beja2.jpg", "cbs.jpg", "medecus.jpg","cwmobile.jpg", "surrey.jpg", "copia.jpg", "rayholman.jpg", "web_goblin-hill.jpg", "cwjf.jpg", "web_swa.jpg", "bigcity.jpg", "web_02.jpg", "web_03.jpg", "web_01.jpg", "web_grace-corp.jpg", "web_11.jpg", "web_internet-jungle.jpg", "web_15.jpg", "web_23.jpg");

OnlineArray = new Array("scotia-dbg.jpg", "scotia-podcast.jpg", "buju.jpg", "veith.jpg", "veith2.jpg", "cpj-amarula-indulgence.jpg", "cpj-fb-tab-amarula-indulgence.jpg","cpj-fb-tab-arizona-green-tea.jpg", "cpj-fb-tab-arizona-rasberry-iced-tea-cube-infusion.jpg","cpj-fb-tab-finlandia-mojito.jpg", "cpj-fb-tab-remy-martin.jpg", "cpj-fb-tab-win-a-bottle-b.jpg", "scotia-fb-trust-fund-contest-tab2.jpg", "Scotia-Tab-1c.jpg", "Scotia-Tab-2c.jpg", "Scotia-Tab-3c.jpg", "games.jpg", "4grocket.jpg", "jusbuss.jpg", "bbb.jpg", "bunny.jpg");

thisPic = 0;
AdvCt = AdvArray.length - 1;
WebCt = WebArray.length - 1;
OnlineCt = OnlineArray.length - 1;
var theTimeOut;
var imgCt = AdvCt;
var myPix = WebArray;
var theFolder = "files/original-portfolio/showCase_Web/";

function chgArray(theArray){
 if(theArray == "Adv"){
	imgCt = AdvCt;
	myPix = AdvArray;
	theFolder = "files/original-portfolio/showCase_Adv/";

	document.heading.src = "files/original-portfolio/portfHead_Adv.gif";

}else if(theArray == "Web"){
	imgCt = WebCt;
	myPix = WebArray;
	theFolder = "files/original-portfolio/showCase_Web/";

	document.heading.src = "files/original-portfolio/portfHead_Web.gif";
}
else{
 	if(theArray == "Online"){
	imgCt = OnlineCt;
	myPix = OnlineArray;
	theFolder = "files/original-portfolio/showCase_Online/";

	document.heading.src = "files/original-portfolio/portfHead_Online.gif";
	}
}

thisPic = 0;
clearTimeout(theTimeOut);
document.portfolioImg.src = theFolder+ myPix[0]
}

function chgSlide(direction){
clearTimeout(theTimeOut);
if(document.images){
thisPic = thisPic + direction
if(thisPic > imgCt){
thisPic = 0
}
if(thisPic < 0){
thisPic = imgCt
}

document.portfolioImg.src = theFolder + myPix[thisPic]
}
}

function showFirst(){
document.portfolioImg.src = theFolder + myPix[0];
thisPic = 0;
clearTimeout(theTimeOut);
}

function showLast(){
document.portfolioImg.src = theFolder + myPix[imgCt];
thisPic =  imgCt;
clearTimeout(theTimeOut);
}

function autoRun(){
	if(document.portfolioImg.complete){
	thisPic ++
	if(thisPic == imgCt +1){
	thisPic = 0
	}

	document.portfolioImg.src = theFolder + myPix[thisPic]
	theTimeOut = setTimeout("autoRun()", 2 * 1000);
	}
}

<!-- OPEN MOVIES IN NEW WINDOW -->
function OpenMovie(theMovie, theWidth, theHeight){
movieURL = "files/original-portfolio/flashPortfolio/"+ theMovie;
movieSize = "width="+theWidth+",height="+theHeight;
var MovieWindow = window.open(movieURL, "MovieWindow", movieSize);
}

<!-- OPEN WEBSITE IN NEW WINDOW -->
function OpenSite(theSite){
siteURL = "http://www."+ theSite;
var SiteWindow = window.open(siteURL, "SiteWindow");
}
