
smallSizes = new Array(77,77);
mediumSizes = new Array(200,170);
pageName = 'portfolio.htm';
scriptName = 'portfolio.js';
countX = 2;
countY = 4;

// sections: name, small images path, medium images path, big images path
// images: name, src, big width, big height
   var arImages = new Array(
							
    new Array('Brick','images/portfolio/small/','images/portfolio/medium/','images/portfolio/big/',
     new Array(
      new Array('Photo 1','Brick 010.jpg',534,400),
      new Array('Photo 2','Brick 011.jpg',534,400),
      new Array('Photo 3','Brick 012.jpg',534,400)
    )
  ),

    new Array('Fireplaces','images/portfolio/small/','images/portfolio/medium/','images/portfolio/big/',
     new Array(
      new Array('Photo 1','DSC00835.jpg',534,400),
      new Array('Photo 2','DSC00857.jpg',534,400),
      new Array('Photo 3','New Website 018.jpg',534,400),
      new Array('Photo 4','New Website 031.jpg',300,400),
      new Array('Photo 5','New Website 032.jpg',300,400),
      new Array('Photo 6','New Website 033.jpg',534,400),
      new Array('Photo 7','New Website 041.jpg',534,400),
      new Array('Photo 8','Picture 007.jpg',534,400),
      new Array('Photo 9','StoneCraftJacob 015.jpg',534,400),
      new Array('Photo 10','StoneCraftJacob 016.jpg',534,400),
      new Array('Photo 11','StoneCraftJacob 030.jpg',300,400),
      new Array('Photo 12','StoneCraftJacob 040.jpg',300,400),
      new Array('Photo 13','StoneCraftJacob 046.jpg',534,400)
    )
  ),

    new Array('Homes','images/portfolio/small/','images/portfolio/medium/','images/portfolio/big/',
     new Array(
      new Array('Photo 1','DSC00637.jpg',534,400),
      new Array('Photo 2','New Website 007.jpg',534,400),
      new Array('Photo 3','New Website 022.jpg',534,400),
      new Array('Photo 4','New Website 023.jpg',534,400),
      new Array('Photo 5','New Website 024.jpg',534,400),
      new Array('Photo 6','New Website 025.jpg',534,400),
      new Array('Photo 7','New Website 026.jpg',534,400),
      new Array('Photo 8','New Website 027.jpg',534,400),
      new Array('Photo 9','New Website 029.jpg',534,400),
      new Array('Photo 10','New Website 034.jpg',534,400),
      new Array('Photo 11','New Website 035.jpg',534,400),
      new Array('Photo 12','T house pic 007.jpg',534,400),
      new Array('Photo 13','StoneCraftJacob 001.jpg',534,400),
      new Array('Photo 14','StoneCraftJacob 002.jpg',534,400),
      new Array('Photo 15','StoneCraftJacob 003.jpg',534,400),
      new Array('Photo 16','StoneCraftJacob 004.jpg',534,400),
      new Array('Photo 17','StoneCraftJacob 005.jpg',534,400),
      new Array('Photo 18','StoneCraftJacob 006.jpg',534,400),
      new Array('Photo 19','StoneCraftJacob 010.jpg',534,400),
      new Array('Photo 20','StoneCraftJacob 011.jpg',534,400),
      new Array('Photo 21','StoneCraftJacob 012.jpg',534,400),
      new Array('Photo 22','StoneCraftJacob 013.jpg',534,400),
      new Array('Photo 23','StoneCraftJacob 014.jpg',534,400),
      new Array('Photo 24','StoneCraftJacob 017.jpg',300,400),
      new Array('Photo 25','StoneCraftJacob 018.jpg',534,400),
      new Array('Photo 26','StoneCraftJacob 019.jpg',534,400),
      new Array('Photo 27','StoneCraftJacob 020.jpg',534,400),
      new Array('Photo 28','StoneCraftJacob 021.jpg',534,400),
      new Array('Photo 29','StoneCraftJacob 022.jpg',534,400),
      new Array('Photo 30','StoneCraftJacob 023.jpg',534,400),
      new Array('Photo 31','StoneCraftJacob 024.jpg',534,400),
      new Array('Photo 32','StoneCraftJacob 025.jpg',534,400),
      new Array('Photo 33','StoneCraftJacob 026.jpg',534,400),
      new Array('Photo 34','StoneCraftJacob 027.jpg',534,400),
      new Array('Photo 35','StoneCraftJacob 029.jpg',534,400),
      new Array('Photo 36','StoneCraftJacob 033.jpg',534,400),
      new Array('Photo 37','StoneCraftJacob 034.jpg',534,400),
      new Array('Photo 38','StoneCraftJacob 035.jpg',534,400),
      new Array('Photo 39','StoneCraftJacob 036.jpg',534,400),
      new Array('Photo 40','StoneCraftJacob 037.jpg',534,400),
      new Array('Photo 41','StoneCraftJacob 038.jpg',534,400),
      new Array('Photo 42','StoneCraftJacob 039.jpg',300,400)
    )
  ),

    new Array('OutdoorKitchens','images/portfolio/small/','images/portfolio/medium/','images/portfolio/big/',
     new Array(
      new Array('Photo 1','New Website 008.jpg',534,400),
      new Array('Photo 2','New Website 009.jpg',534,400),
      new Array('Photo 3','New Website 010.jpg',534,400),
      new Array('Photo 4','New Website 030.jpg',534,400),
      new Array('Photo 5','New Website 036.jpg',534,400)
    )
  ),

    new Array('Patios','images/portfolio/small/','images/portfolio/medium/','images/portfolio/big/',
     new Array(
      new Array('Photo 1','New Website 014.jpg',534,400),
      new Array('Photo 2','New Website 016.jpg',534,400),
      new Array('Photo 3','New Website 017.jpg',534,400),
      new Array('Photo 4','New Website 019.jpg',534,400),
	  new Array('Photo 5','Patios053.jpg',534,400),
      new Array('Photo 6','Patios061.jpg',534,400),
      new Array('Photo 7','Patios063.jpg',534,400),
      new Array('Photo 8','Patios064.jpg',534,400),
      new Array('Photo 9','Patios083.jpg',300,400)

    )
  ),

  new Array('Pavestone','images/portfolio/small/','images/portfolio/medium/','images/portfolio/big/',
    new Array(
      new Array('Photo 1','Pavestone119.jpg',534,400)
    )
  ),


    new Array('Retaining Walls','images/portfolio/small/','images/portfolio/medium/','images/portfolio/big/',
     new Array(
      new Array('Photo 1','StoneCraftJacob 028.jpg',534,400),
	  new Array('Photo 2','Retaining 007.jpg',534,400),
      new Array('Photo 3','Retaining 008.jpg',534,400),
      new Array('Photo 4','Retaining 009.jpg',534,400),
      new Array('Photo 5','Retaining 013.jpg',534,400),
      new Array('Photo 6','Retaining 014.jpg',534,400),
      new Array('Photo 7','Retaining 016.jpg',300,400),
      new Array('Photo 8','Retaining 017.jpg',534,400),
      new Array('Photo 9','Retaining 018.jpg',300,400),
      new Array('Photo 10','Retaining 038.jpg',534,400),
      new Array('Photo 11','Retaining 041.jpg',534,400),
      new Array('Photo 12','Retaining 042.jpg',534,400),
      new Array('Photo 13','Retaining 043.jpg',534,400),
      new Array('Photo 14','Retaining 046.jpg',534,400),
      new Array('Photo 15','Retaining 048.jpg',534,400),
      new Array('Photo 16','Retaining 049.jpg',534,400),
      new Array('Photo 17','Retaining 054.jpg',534,400),
      new Array('Photo 18','Retaining 056.jpg',534,400),
      new Array('Photo 19','Retaining 069.jpg',534,400),
      new Array('Photo 20','Retaining 071.jpg',534,400),
      new Array('Photo 21','Retaining 080.jpg',534,400),
      new Array('Photo 22','Retaining 092.jpg',534,400),
      new Array('Photo 23','Retaining 096.jpg',300,400),
      new Array('Photo 24','Retaining 106.jpg',534,400),
      new Array('Photo 25','Retaining 111.jpg',534,400),
      new Array('Photo 26','Retaining 115.jpg',300,400),
      new Array('Photo 27','Retaining 116.jpg',534,400),
      new Array('Photo 28','Retaining 120.jpg',534,400),
      new Array('Photo 29','Retaining 121.jpg',534,400),
      new Array('Photo 30','Retaining 122.jpg',300,400),
      new Array('Photo 31','Retaining 123.jpg',300,400),
      new Array('Photo 32','Retaining 124.jpg',534,400)	  
	)
  ),

    new Array('Waterfeatures','images/portfolio/small/','images/portfolio/medium/','images/portfolio/big/',
     new Array(
      new Array('Photo 1','New Website 041.jpg',534,400)
	  
    )
  )
)
 
section = getParameter(self.document.location.href, 'section');
if (isNaN(section) || (section=='') || (section<0) || (section>arImages.length))
  section = 0; 

ind = getParameter(self.document.location.href, 'ind');
if (isNaN(ind) || (ind=='') || (ind<0) || (ind>arImages[section][4].length))
  ind = 0; 

var arPreloadImages = new Array();
function preload() {
  if (arImages[section][2]!='') {
    for (i=ind;(i<(Number(ind)+Number(countX*countY))) && (i<arImages[section][4].length);i++) {
      arPreloadImages[i] = new Image(mediumSizes[0],mediumSizes[1]);
      arPreloadImages[i].src = arImages[section][2]+arImages[section][4][i][1];
    }
  }
}
  
function showImageMedium(number) {
  showImage('imagemedium',arImages[section][2]+arImages[section][4][number][1]);
  showMessage('imagemediumname',arImages[section][4][number][0]);
}

function showImageBig(number) {
  showImagePopup(scriptName,section,number,arImages[section][4][number][2],
   arImages[section][4][number][3]);
}
