	window.addEvent('domready', function(){
// Call Mootools for the scroll effect
			var scroll = new Fx.Scroll('holder', {
				wait: false,
				duration: 2500,
				transition: Fx.Transitions.Quad.easeInOut
			});
// Get all list items which contain images, and loop through them
			var theHolder = document.getElementById('holder');
			var thePictures = theHolder.getElementsByTagName('li');
			for ( i=0; i < thePictures.length; i++) {
// Get all anchors which are children of the list items, and loop through them
				var theLinks = thePictures[i].getElementsByTagName('a');
				for ( x=0; x < theLinks.length; x++ ) {
					var theClass = theLinks[x].className;
					if ( theClass == 'fwd') {
						theLinks[x].onclick = function(event) {
//						theLinks[x].addEvent('click', function() {
							event = new Event(event).stop();
							var y = this.parentNode.parentNode.getAttribute('id');
							var y = parseInt(y.charAt(y.length - 1));
							scroll.toElement('picture' + (y + 1));
						};
					}
					else if ( theClass == 'bck') {
						theLinks[x].onclick = function(event) {
//						theLinks[x].addEvent('click', function(event) {
							event = new Event(event).stop();
							var y = this.parentNode.parentNode.getAttribute('id');
							var y = parseInt(y.charAt(y.length - 1));
							scroll.toElement('picture' + (y - 1));
						};
					}
				}
			}			
		});