$(document).ready(function() {
				
					var ooak=0;
					outfitChange();
				
					$("#ooak-next").mouseup(function() {					
						if(ooak<8) { ooak++ } else { ooak=1 }
						outfitChange();					
					});
					
					$("#ooak-view").mouseup(function() {					
						ooak=1;
						outfitChange();					
					});
					
					$("#ooak-prev").mouseup(function() {
						if(ooak>1) { ooak-- } else { ooak=8 }
						outfitChange();					
					});
					
					function outfitUpdate(outfitLink, outfitImage) {
						$("a#ooak-shop").attr("href", outfitLink);	
						$("div#ooak-wrapper").attr("style", "background-image:url(" + outfitImage + ");display:none;" );
					}
					
					function outfitChange() {
						
						$("div#ooak-wrapper").hide();
						
						switch(ooak) {
							
							case 0:
								$("a#ooak-view").show().css("z-index", "9999");
								$("a#ooak-prev").hide();
								$("a#ooak-shop").hide();
								$("a#ooak-next").hide();
								outfitUpdate("javascript:void(0);", "http://static0.modcloth.com/images/assets/0000/0777/intro.jpg");
								break;
								
							case 1:
								$("a#ooak-view").remove();
								$("a#ooak-prev").show();
								$("a#ooak-shop").show();
								$("a#ooak-next").show();
								outfitUpdate("http://www.modcloth.com/store/ModCloth/Vintage+Holiday+Collection+2009/In+the+Meadow", "http://static0.modcloth.com/images/assets/0000/0729/1.jpg")
								break;
							
							case 2:
								outfitUpdate("http://www.modcloth.com/store/ModCloth/Vintage+Holiday+Collection+2009/Love+Me+So", "http://static0.modcloth.com/images/assets/0000/0732/2.jpg")
								break;
							
							case 3:
								outfitUpdate("http://www.modcloth.com/store/ModCloth/Vintage+Holiday+Collection+2009/Frolic+and+Play", "http://static0.modcloth.com/images/assets/0000/0735/3.jpg")
								break;
							
							case 4:
								outfitUpdate("http://www.modcloth.com/store/ModCloth/Vintage+Holiday+Collection+2009/Merry+and+Bright", "http://static0.modcloth.com/images/assets/0000/0738/4.jpg")
								break;
							
							case 5:
								outfitUpdate("http://www.modcloth.com/store/ModCloth/Vintage+Holiday+Collection+2009/Dream+by+the+Fire", "http://static0.modcloth.com/images/assets/0000/0741/5.jpg")
								break;
							
							case 6:
								outfitUpdate("http://www.modcloth.com/store/ModCloth/Vintage+Holiday+Collection+2009/Harps+of+Gold", "http://static0.modcloth.com/images/assets/0000/0744/6.jpg")
								break;
							
							case 7:
								outfitUpdate("http://www.modcloth.com/store/ModCloth/Vintage+Holiday+Collection+2009/Eyes+All+Aglow", "http://static0.modcloth.com/images/assets/0000/0747/7.jpg")
								break;
							
							case 8:
								outfitUpdate("http://www.modcloth.com/store/ModCloth/Vintage+Holiday+Collection+2009/Sing+a+Love+Song", "http://static0.modcloth.com/images/assets/0000/0750/8.jpg")
								break;
								
						}
						
						$("div#ooak-wrapper").fadeIn(500);
					}
														   
			   	});
