// adjust ligtbox default values...

	var resizeSpeed = 10;
	
	
	
//	MODIFY LIGHTBOX SO THAT IF AN ARRAY OF CAPTIONS EXISTS, WE
//	USE THE CAPTION FROM THE ARRAY RATHER THAN THE TITLE ATTRIBUTE

	var fl_lightboxCaptions = new Array();
	
	Lightbox.prototype.start = function(imageLink) {

		hideSelectBoxes();

		// stretch overlay to fill page and fade in
		var arrayPageSize = getPageSize();
		Element.setHeight('overlay', arrayPageSize[1]);
		new Effect.Appear('overlay', { duration: 0.2, from: 0.0, to: 0.8 });

		imageArray = [];
		imageNum = 0;		

		if (!document.getElementsByTagName){ return; }
		var anchors = document.getElementsByTagName('a');

		// if image is NOT part of a set..
		if((imageLink.getAttribute('rel') == 'lightbox')){
			// add single image to imageArray
			/*	:REM: BY PETER 070620
			imageArray.push(new Array(imageLink.getAttribute('href'), imageLink.getAttribute('title')));			
			:/REM: */
			//	:REPLACE:
			var caption = (fl_lightboxCaptions.length > i) ? fl_lightboxCaptions[i] : anchor.getAttribute('title');
			imageArray.push(new Array(imageLink.getAttribute('href'), caption));
			//	:/REPLACE:
		} else {
		// if image is part of a set..

			// loop through anchors, find other images in set, and add them to imageArray
			// :ADDED: By Peter
			var active_anchor_index = -1;
			// :/ADDED:
			for (var i=0; i<anchors.length; i++){
				var anchor = anchors[i];
				/*	:REM: BY PETER 070620
				if (anchor.getAttribute('href') && (anchor.getAttribute('rel') == imageLink.getAttribute('rel'))){
					imageArray.push(new Array(anchor.getAttribute('href'), anchor.getAttribute('title')));
				}
				:/REM: */
				//	:REPLACE:
				if (anchor.getAttribute('href') && (anchor.getAttribute('rel') == imageLink.getAttribute('rel'))){
					active_anchor_index ++;
					var caption = (fl_lightboxCaptions.length > active_anchor_index) ? fl_lightboxCaptions[active_anchor_index] : anchor.getAttribute('title');
					imageArray.push(new Array(anchor.getAttribute('href'), caption));
				}
				//	:/REPLACE:
			}
			imageArray.removeDuplicates();
			while(imageArray[imageNum][0] != imageLink.getAttribute('href')) { imageNum++;}
		}

		// calculate top offset for the lightbox and display 
		var arrayPageSize = getPageSize();
		var arrayPageScroll = getPageScroll();
		var lightboxTop = arrayPageScroll[1] + (arrayPageSize[3] / 15);

		Element.setTop('lightbox', lightboxTop);
		Element.show('lightbox');
		
		this.changeImage(imageNum);
	};