<!DOCTYPE html>
<html lang="en">
<head>
<?php
  require 'php/setVariables.php';
  $keywords = "gallery";
  $description = "Custom Cutting and Serving boards";
  $title = "Gallery | Dick's Harwood Creations";
  require 'req/header.php';
?>
    <script src="galleria/galleria-1.5.7.min.js"></script>
</head>
<body>
    <div class="bodyFrame">


        <?php require 'req/topPage.php'; ?>

        <!-- begin content -->
        <main>

        <section>
            <div class="pageFull topi">
              <div class="pageSize">
                  <div class="subPage galTop">
                    <h1>Gallery</h1>
                  </div>
              </div>
            </div>
        </section>



           <section>
            <div class="pageFull">

                <div class="centerGalle">
                    
                  <div class="publikBoxWrap">
				<div class="publikGalleria">
				<?php       
										
										
										// folder with images for this slider defined in php/contentPages.php
										$folder = 'images/gallery/boards';
										
										
                    $allowed_filetypes = array('.jpg','.gif','.png','.bmp'); 
                    $path_thumnails = opendir($folder); 
                    $pic = array();
                    $i= 0;
                    while (false !== ($entry = readdir($path_thumnails))){ 
                        $ext = substr($entry,strpos($entry,'.'),strlen($entry)-1);
                        if(in_array($ext,$allowed_filetypes)) {
                            $pic[$i] = $entry;
                            $i++;
                        }
                    }
                    for($i=0; $i < sizeof($pic) ; $i++) {       
											echo '<img src="'.$folder.'/'.$pic[$i].'" alt="work sample">';                                         
                    }closedir($path_thumnails);                       
						?>  
				</div>
			</div>
                    
                    
                 </div><!-- End centerGalle -->

            </div><!-- end pageFull topi -->
          </section>












        </main>
         <!-- end content -->

<?php require 'req/footer.php'; ?>

    </div><!-- end bodyFrame -->

    <script>
(function() { 
    Galleria.loadTheme('galleria/themes/folio/galleria.folio.min.js');
		Galleria.configure({
    _center: true,
});
    Galleria.run('.publikGalleria');
}());
</script>
</body>
</html>
