//maxPictures: aantal tekeningen in de gallery maxPictures = 130; //pictureArray: bevat het relatieve pad naar de tekeningen pictureArray = new Array(maxPictures); //thumbArray: de thumbnails v/d tekeningen thumbArray = new Array(maxPictures); //nrPic: nr pictureArray[nrPic] van de tekening links van de lijst nrPic = 0; //mainPictureNr: het nummer van het plaatje dat nu de mainPicture is mainPictureNr = 0; //initPics: laadt de tekeningen in de array pictureArray function init() { if (document.images) { for (i=maxPictures; i>-1; i--) { pictureArray[maxPictures - (i+1)] = "pictures/full/image"+(i+1)+".jpg"; thumbArray[maxPictures - (i+1)] = "pictures/thumb/thumb_image"+(i+1)+".jpg"; } //preloaden van de thumbnails tmp_image = new Image(120,120); for (j=0; j 0) { getGallery(-1); if (nrPic == 0) { document.getElementById("terug").style.visibility = 'hidden'; } } if (richting == 'right' && nrPic < (maxPictures -5)) { getGallery(1); if (nrPic == (maxPictures -5)) { document.getElementById("verder").style.visibility = 'hidden'; } } }; function loadGallery() { teller = 0; gallery = ""; rest = ""; for (i=0; i'; plaatje += ''; plaatje += ''; plaatje += ''; gallery += plaatje; } gallery += '

'; } x = (maxPictures%5); if (x > 0) { gallery += ''; for (k=0; k < x; k++) { teller++; rest = ''; gallery += rest; } gallery += '
'; rest += ''; rest += ''; rest += ''; rest += ''; rest += '
'; rest += '

'; } document.getElementById("full_gallery").innerHTML = gallery; getThumbnails(); }; function getThumbnails() { if (document.images) { for (i=maxPictures; i>-1; i--) { pictureArray[maxPictures - (i+1)] = "pictures/full/image"+(i+1)+".jpg"; thumbArray[maxPictures - (i+1)] = "pictures/thumb/thumb_image"+(i+1)+".jpg"; } }; for (i=0; i< maxPictures; i++) { thumbn = document.getElementById("pic"+(i+1)); thumbn.setAttribute('src', thumbArray[i]); } }; function getMainPicture() { picture = document.getElementById("mainPicture"); picture.setAttribute('src', "pictures/full/image"+maxPictures+".jpg"); picture.setAttribute('style', "cursor:hand"); }; function openMainImage() { window.open("onepicture.php?pictureNr="+maxPictures); }; //frustraties alom met IE7+ grrr met picture.setAttribute('onClick', "window.open...") had het moeten //werken in functie switchMainPic maar dat werkt dus niet ! function openNewPictureWindow() { picture = document.getElementById("mainPicture"); window.open("onepicture.php?pictureNr="+mainPictureNr); };