var path=""; var images = []; var image_captions = []; var num_images = 15; var current_image = 0; images[0] = '01asra16.jpg'; image_captions[0] = 'Auburn State Recreation Area, CA'; images[1] = '02foresthill-2-16.jpg'; image_captions[1] = 'Foresthill Bridge, CA'; images[2] = '03foresthill16.jpg'; image_captions[2] = 'Foresthill Bridge, CA'; images[3] = 'cascadehigh16.jpg'; image_captions[3] = 'Auburn Lake Trails, CA'; images[4] = 'cascadesat16.jpg'; image_captions[4] = 'Private Residence, Cool, CA'; images[5] = 'clubhouse.jpg'; image_captions[5] = 'Auburn Lake Trails Clubhouse Construction'; images[6] = 'confluence16.jpg'; image_captions[6] = 'American River Confluence, CA'; images[7] = 'cool16.jpg'; image_captions[7] = 'Cool, CA'; images[8] = 'donner.imgp0732.jpg'; image_captions[8] = 'Donner Summit'; images[9] = 'forestsky16.jpg'; image_captions[9] = 'American River Valley, CA'; images[10] = 'northside16.jpg'; image_captions[10] = 'Northside Elementary School, Cool, CA'; images[11] = 'pitter16.jpg'; image_captions[11] = 'Pitter Ranch, Tehema County, CA'; images[12] = 'salmonfalls16.jpg'; image_captions[12] = 'Salmon Falls Bridge, Folsom, CA'; images[13] = 'salmonriver16.jpg'; image_captions[13] = 'American River, Folsom, CA'; images[14] = 'susanville0914.16.jpg'; image_captions[14] = 'Susanville, CA'; function refresh_right_image() { var image_id=document.getElementById('right_image'); var caption_id=document.getElementById('right_image_caption'); if (current_image == (num_images-1)) { current_image = 0; } else { current_image++; } image_id.src = "portfolio/rotate-images/"+images[current_image]; caption_id.innerHTML = image_captions[current_image]; setTimeout("refresh_right_image()", 8000); } function addEvent( obj, type, fn ) { if ( obj.attachEvent ) { obj['e'+type+fn] = fn; obj[type+fn] = function(){obj['e'+type+fn]( window.event );} obj.attachEvent( 'on'+type, obj[type+fn] ); } else obj.addEventListener( type, fn, false ); } function removeEvent( obj, type, fn ) { if ( obj.detachEvent ) { obj.detachEvent( 'on'+type, obj[type+fn] ); obj[type+fn] = null; } else obj.removeEventListener( type, fn, false ); }