<?php require_once ('customfunctions.php'); 
$themeResult = getTheme($zenCSS, $themeColor, 'effervescence');
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>

<title><?php printGalleryTitle(); ?> | <?php echo getAlbumTitle();?> | <?php echo getImageTitle();?></title>
<link rel="stylesheet" href="<?php echo $zenCSS ?>" type="text/css" />
<link rel="stylesheet" href="<?php echo FULLWEBPATH . "/" . ZENFOLDER ?>/js/thickbox.css" type="text/css" />
<script type="text/javascript" src="<?php echo  $_zp_themeroot ?>/scripts/bluranchors.js"></script>
<script src="<?php echo FULLWEBPATH . "/" . ZENFOLDER ?>/js/jquery.js" type="text/javascript"></script>
<script src="<?php echo FULLWEBPATH . "/" . ZENFOLDER ?>/js/thickbox.js" type="text/javascript"></script>
<?php zenJavascript(); ?>


</head>

<body onload="blurAnchors()">

<!-- Wrap Everything -->
<div id="main4">
  <div id="main2">
  
<!-- Wrap Header -->
    <div id="galleryheader">
      <div id="gallerytitle">

<!-- Image Navigation -->
        <div class="imgnav">
          <div class="imgprevious">
            <?php 
            global $_zp_current_image;
            if (hasPrevImage()) { 
              $image = $_zp_current_image->getPrevImage();
              echo '<a href="' . getPrevImageURL() . '" title="' . $image->getTitle() . '">&laquo; prev</a>';
              } else {
            echo '<div class="imgdisabledlink">&laquo; prev</div>'; 
            }
            ?>
            </div>
		  <div class="imgnext">
            <?php
            if (hasNextImage()) { 
              $image = $_zp_current_image->getNextImage();
              echo '<a href="' . getNextImageURL() . '" title="' . $image->getTitle() . '">next &raquo;</a>';
            } else {
              echo '<div class="imgdisabledlink">next &raquo;</div>';
            }
            ?>
          </div>
        </div>

<!-- Logo -->
        <div id="logo2">
        <?php 
          echo '<h1><a href="' . getMainSiteURL() . '" title="Visit ' . getMainSiteName() . '">' . $_SERVER['HTTP_HOST'] . '</a></h1>';
        ?>
        </div>
      </div>

<!-- Crumb Trail Navigation -->
      <div id="wrapnav">
        <div id="navbar">
          <span><a href="<?php echo getGalleryIndexURL();?>" title="Albums Index"><?php echo getGalleryTitle();?>
          </a> | <?php printParentBreadcrumb(); ?><a href="<?php echo getAlbumLinkURL();?>" title="Album Thumbnails"><?php echo getAlbumTitle();?></a> | 
          </span> <?php printImageTitle(true); ?>
          </div>
      </div>
    </div>

<!-- The Image -->
  <div id="image">
    <a href="<?php echo getFullImageURL();?>" title="<?php echo getImageTitle();?>"><?php printDefaultSizedImage(getImageTitle()); ?></a> 
    <?php 
	$MAP = printImageMap();
	if (getImageEXIFData()) {
	  echo "<div id=\"exif_link\"><a href=\"#TB_inline?height=400&width=300&inlineId=imagemetadata\" title=\"image details from exif\" class=\"thickbox\">Image Info</a></div>";
	  printImageMetadata('', false); 
	}
	//if (hasMapData()) { css not up to par yet
	  //echo "<div id=\"map_link\"><a href=\"#TB_inline?height=500&width=595&inlineId=map\" class=\"thickbox\">View Map</a></div>";
	  //printImageMap(); 
	//}
	?>
  </div>
  <br clear="all" />
</div>  

<!-- Image Description -->
  <div id="description"><?php printImageDesc(true); ?></div>

</div>

<!-- Wrap Bottom Content -->
<?php if (getOption('Allow_comments')) { ?>
<div id="content">

<!-- Headings -->
  <div id="bottomheadings">
    <div class="bottomfull">
    <?php $num = getCommentCount(); echo ($num == 1) ? ("<h3>1 Comment</h3>") : ("<h3>$num Comments</h3>"); ?>
    </div>
  </div>

<!-- Wrap Comments -->
  <div id="main3">

    <div id="comments">
    <?php while (next_comment()):  ?>
    <div class="comment">
      <div class="commentinfo">
        <h4><?php printCommentAuthorLink(); ?></h4>: on <?=getCommentDate();?>, <?=getCommentTime();?><?php printEditCommentLink('Edit', ', ', ''); ?>
      </div>
      <div class="commenttext"><?=getCommentBody();?></div>
    </div>
    <?php endwhile; ?>
  </div>

<!-- Comment Box -->
    <?php if (OpenedForComments()) { ?>
      <div id="commentbox">
        <h3>Leave a Reply</h3>
        <form id="commentform" action="#" method="post">
          <div><input type="hidden" name="comment" value="1" />
            <input type="hidden" name="remember" value="1" />
            <?php printCommentErrors(); ?>
            <p><input type="text" name="name" id="name" class="textinput" value="<?=$stored[0];?>" size="22" tabindex="1" />
            <label for="name"><small>Name</small></label></p>
            <p><input type="text" name="email" id="email" class="textinput" value="<?=$stored[1];?>" size="22" tabindex="2" />
            <label for="email"><small>Mail</small></label></p>
            <p><input type="text" name="website" id="website" class="textinput" value="<?=$stored[2];?>" size="22" tabindex="3" />
            <label for="website"><small>Website</small></label></p>
            <p><textarea name="comment" id="comment" rows="5" cols="100%" tabindex="4"></textarea></p>
            <p><input type="submit" value="Submit" class="pushbutton" /></p>
          </div>
        </form>
      </div>
    <?php } ?>

  </div>
</div>
<?php } ?>

<!-- Footer -->
<div class="footlinks">
  <?php printThemeInfo(); ?>
  <a href="http://www.zenphoto.org" title="A simpler web photo album">Powered by 
  <font face="Arial Narrow" size="4">zen</font><span style="font-variant: small-caps"><font face="Arial Black" size="1">photo</font></span></a>
</div>

<?php printAdminToolbox(); ?>
 
</body>
</html>
