var theImages = new Array() 
theImages[0] = 'imgindex/tatuindex.png'
theImages[1] = 'imgindex/veneraindex.png'
theImages[2] = 'imgindex/hennaindex.png'
theImages[3] = 'imgindex/cocaindex.png'
theImages[4] = 'imgindex/pajaroindex.png'
theImages[5] = 'imgindex/gatokallawayaindex.png'
theImages[6] = 'imgindex/patokallawayaindex.png'

var j = 0
var p = theImages.length;
var preBuffer = new Array()
for (i = 0; i < p; i++){
   preBuffer[i] = new Image()
   preBuffer[i].src = theImages[i]
}
var whichImage = Math.round(Math.random()*(p-1));
function showImage(){
document.write('<div class="centro"'+'><img src="'+theImages[whichImage]+'" alt="indexpict" /><'+'/div>');
}
