function returnInfo(dressNumber)
{
	var statsArr = [3, 3, 2, 3, 3, 3, 3, 3, 4, 3, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, 3];
	var infoArr = []; 
	infoArr[0] =  ['RB A034', 'Strapless, high-waisted, A-line gown made of Italian satin. The bodice is overlaid in beaded lace, with bead detail along the top and at the waistline. The chapel length train is detachable. Available in white with white/silver lace, or in ivory with ivory/champagne/silver lace.', statsArr[0], '8034_l.jpg', '8034_d.jpg', '8034_b.jpg'];
	infoArr[1] =  ['RB A044', 'Strapless, asymmetric tiered, fitted gown of luxury satin and lace, with a chapel train. Trimmings include beading, sequins and pearls. Available in white with white and silver lace, or Ivory with ivory and gold lace.', statsArr[1], '8044F.jpg', '8044_b.jpg', '8044_d.jpg'];
	infoArr[2] =  ['RB A045', 'Strapless, silky satin gown with a sweetheart neckline. The bodice and skirt are heavily embellished with beading and embroidery. Chapel length train. Available in white with silver embroidery, or ivory with champagne and gold embroidery.', statsArr[2], '8045F.jpg', 'S4300728.JPG'];
	infoArr[3] =  ['RB A068', 'Strapless organza and rich satin sheath overlaid with lace and beaded accents. It has a gathered waist and a detachable organza train. Available in white, ivory or deep ivory.', statsArr[3], '8068F.jpg', '8068_d.jpg', '8068B.jpg'];
	infoArr[4] =  ['RB B025', 'Full, strapless gown made of matte satin with a basque waistline.and chapel length train. The bodice is embellished with beading and lace. Available in white or ivory.', statsArr[4], '5025F.jpg', '5025_b.jpg', '5025_d.jpg'];
	infoArr[5] =  ['RB B041', 'Strapless luxury satin gown with a full flowing skirt. The corseted bodice is embellished with beading and embroidery and features a dropped waistline with a gathered detail. Chapel length train. Available in white or ivory with silver embroidery.', statsArr[5], '5041F.jpg', '5041_d.jpg', '5041B.jpg'];
	infoArr[6] =  ['RB B043', 'Matte satin gown with a scoop neckline and A-line skirt. The bodice features a gathered asymmetric waist and is embellished with lace and beading. Chapel length train. Available in white or ivory.', statsArr[6], '5043F.jpg', '5043_d.jpg', '5043B.jpg'];
	infoArr[7] =  ['RB B045', 'Strapless organza and matte satin gown with an A-line, asymmetrically tiered skirt. The tiers are embellished with lace and beading. The back has a chapel length train. Available in white with silver lace, or ivory with gold lace.', statsArr[7], '5045F.jpg', '5045_d.jpg', '5045B.jpg'];
	infoArr[8] =  ['RB B049', 'This matte satin gown has a strapless sweetheart neckline with a border in a contrast color to match the full A-line skirt. It has beading and embroidery accents on the bust line, waistline and hemline. The V-back has a chapel length train. Available in white or ivory, with the contrast available in any colour.', statsArr[8], '5049.jpg', '5049_b.jpg', '5049_d.jpg', '5049_l.jpg'];
	infoArr[9] =  ['RB B051', 'Matte satin, strapless gown with a dropped waistline and a chapel length train. The bodice and full skirt are accented with beading and embroidery. Available in white or ivory.', statsArr[9], '5051.jpg', '5051_b.jpg', '5051_d.jpg'];
	infoArr[10] = ['RB B052', 'Light Italian satin, strapless gown has beading and lace on the bodice. The asymmetric waistline is accented with beaded pleating. The A-Line skirt has a chapel length train. Available in white, ivory or ivory with blush.', statsArr[10], '5052.jpg', '5052_b.jpg', '5052_d.jpg', '5052_l.jpg'];
	infoArr[11] = ['RB B058', 'Strapless, taffeta gown with a sweetheart neckline. It has beaded and gathered accents on the bodice and waistline. The trumpet shaped floor length skirt has a chapel length train. Available in white or ivory.', statsArr[11], '5058_l.jpg', '5058_b.jpg', '5058_d.jpg'];
	infoArr[12] = ['RB C180', 'Strapless, matte satin gown with satin border along the sweetheart neckline. The waistline features a small satin bow. The bottom of the gown and the train are embellished with lace and beading. Chapel length train. Available in white, ivory or ivory with blush.', statsArr[12], '2180F.jpg', '2180B.jpg', 'S4300725.JPG'];
	infoArr[13] = ['RB C188', 'A matte satin gown with the upper part of the bodice overlaid with beaded lace. The shoestring straps are made of beaded lace. The dropped waistline is accented with beading, and the skirt and train are embellished with sequins and beading. Chapel length train. Available in white with white lace, or ivory with ivory or blush lace.', statsArr[13], '2188F.jpg', '2188B.jpg', 'S4300720.JPG'];
	infoArr[14] = ['RB C191', 'Strapless, matte satin, fitted gown with beading and embroidery along the neckline and waistline. The bottom of the gown features chiffon inserts on the sides, embellished with embroidery. Medium length train. Available in white or ivory with silver embroidery.', statsArr[14], '2191F.jpg', '2191B.jpg', 'S4300719.JPG'];
	infoArr[15] = ['RB C196', 'This V-neck, A-line matte satin gown features beading and embroidery at the neckline, hemline and the front and the back of skirt. The back has a deep V and a chapel length train. Available in white or ivory with silver detail.', statsArr[15], '2196F.jpg', '2196_d.jpg', '2196B.jpg'];
	infoArr[16] = ['RB C207', 'Strapless silky satin gown with a full, floor length skirt and chapel length train. The bodice features a basque waistline. The bodice, train and skirt are all heavily accented with beading and pearls. Available in white with silver embroidery, or ivory with champagne and silver embroidery.', statsArr[16], '2207F.jpg', '2207_d.jpg', '2207B.jpg'];
	infoArr[17] = ['RB C252', 'Strapless, taffeta gown with asymmetric pleating and beaded lace accent. The full gathered skirt is floor length and has a chapel length train. Available in white or ivory.', statsArr[17], '2252_l.jpg', '2252_b.jpg', '2252_d.jpg'];
	infoArr[18] = ['RB C264', 'This matte satin, strapless gown is accented with silver embroidery and beading throughout. The drop waist flows to an A-line skirt with a Chapel length train. Available in white, ivory or deep Ivory.', statsArr[18], '2264_l.jpg', '2264_b.jpg', '2264_d.jpg'];
	infoArr[19] = ['RB C268', 'Light Italian satin, strapless gown is embellished with embroidery and beading. The drop waist flows into the A-line skirt. The back of the skirt has a tiered embellishment and a chapel length train. Available in white or in ivory.', statsArr[19], '2268_l.jpg', '2268_b.jpg', '2268_d.jpg'];
	infoArr[20] = ['RB D124', 'Strapless chiffon gown with corset lace up back. It has an asymmetrical gathered wrap bodice with a side opening skirt. The skirt opens to reveal the satin underneath with delicate metallic embroidery, beads, and sequins. Sweep train. Available in white or ivory with silver embroidery.', statsArr[20], '1124_l.jpg', '1124_b.jpg', '1124_d.jpg'];
	infoArr[21] = ['RB D134', 'Strapless gown of matte satin features beading and embroidery on the bodice and front panel, that peaks through the light chiffon overskirt. The gown has a sweep train. Available in white with white/silver embroidery or ivory with ivory/silver embroidery.', statsArr[21], '1134_l.jpg', '1134_b.jpg', '1134_d.jpg'];
	infoArr[22] = ['RB D151', 'Strapless matte satin gown with beading along the neckline. The skirt features an opening with a beaded border and flower detail. Sweep train. Available in all white or ivory with blush.', statsArr[22], '1151F.jpg', '1151B.jpg'];
	infoArr[23] = ['RB D186', 'This strapless, light Italian satin and chiffon gown has an A-line skirt accented with beading, embroidery and chiffon flowers. The waistline has a belt of gathered chiffon. The gown has a small train and can also be ordered without flowers. Gown available in white or ivory with silver embroidery. Chiffon belt and flowers are available in any colour.', 	statsArr[23], '1186F.jpg', '1186_d.jpg', '1186B.jpg'];
	return infoArr[dressNumber];
}

function menuClicked(whichItem)
{
	var divsArr = ['homeDiv', 'dressDiv', 'accessoriesDiv', 'contactDiv'];
	for(var i= 0; i < divsArr.length; i++)
	{
		if(whichItem != i)
		{
			$(divsArr[i]).style.height = '0%';
			$(divsArr[i]).style.display = 'none';
		}
	}
	$(divsArr[whichItem]).style.height = '100%';
	$(divsArr[whichItem]).style.display = 'block';
}

function dressclicked(which)
{
	var curnum = parseInt($('currDress').innerHTML);
	if(which == 0)
	{
		displayDress(0);
		$('currDress').innerHTML = (0).toString();
	}
	if(which == 1)
	{
		displayDress(curnum-1);
		$('currDress').innerHTML = (curnum-1).toString();
	}
	if(which == 2)
	{
		displayDress(curnum+1);
		$('currDress').innerHTML = (curnum+1).toString();
	}
	if(which == 3)
	{
		displayDress(23);
		$('currDress').innerHTML = (23).toString();
	}
}

function displayDress(dressNum)
{
	if(dressNum > 0)
	{
		$('prevLink').className = 'dressLink2';
		$('prevAllLink').className = 'dressLink2';
		$('prevLink').src = 'image/l_n.png';
		$('prevAllLink').src = 'image/l_e.png';
	}
	else
	{
		$('prevLink').className = 'dressLink';
		$('prevAllLink').className = 'dressLink';
		$('prevLink').src = 'image/l_n_d.png';
		$('prevAllLink').src = 'image/l_e_d.png';
	}
	if(dressNum < 23)
	{
		$('nextLink').className = 'dressLink2';	
		$('nextAllLink').className = 'dressLink2';	
		$('nextLink').src = 'image/r_n.png';
		$('nextAllLink').src = 'image/r_e.png';
	}
	else
	{
		$('nextLink').className = 'dressLink';
		$('nextAllLink').className = 'dressLink';
		$('nextLink').src = 'image/r_n_d.png';
		$('nextAllLink').src = 'image/r_e_d.png';
	}
	var infoArr = [];
	infoArr = returnInfo(dressNum);
	$('dressTitle').innerHTML = infoArr[0];
	$('dressDesc').innerHTML = infoArr[1];
	switchImage('dress/' + infoArr[0] + '/' +infoArr[3]);
	for(var i = 0; i < 4; i++)
	{
		var tempStr = 'pic' + (i+1).toString() + 'link';
		$(tempStr).innerHTML = '';
	}
	for(var i = 0; i < parseInt(infoArr[2]); i++)
	{
		var tempStr = 'pic' + (i+1).toString() + 'link';
		var tempPath = 'dress/' + infoArr[0] + '/' +infoArr[3+i];
		$(tempStr).innerHTML = '<span class="picLink" onclick="switchImage(\'' + tempPath + '\');"> ' + (i+1).toString() + '</span>';
	}
}

function switchImage(path)
{
	$('dressImage').src = path;
}

function initPage()
{
	displayDress(0);
}