Snippets

Image Basic (X)HTML Template

Image Basic CSS Template

Image CSS Horizontal Menu

Image CSS Vertical Menu

Image CSS Dropdown Menu

Image CSS Image Gallery 1

Image Demo
Image Images: preview.gif - img1_large.jpg - img1_thumb.jpg - img2_large.jpg - img2_thumb.jpg

Image Code

Select All and copy to clipboard with <ctrl>+<c>.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<style type="text/css">

body {
  font: normal 13px/1.5em arial, sans-serif;
  margin: 0;
  padding: 0 10px;
  background-color: #fff;
}

.gallerywrapper {
  margin: 0px auto;
  width: 500px;
}

.title {
  color: #999;
  font-size: 3em;
  line-height: 1.1em;
  margin: 165px 0 0 10px;
  position: absolute;
}

ul.gallery, ul.gallery li { margin: 0; padding: 0; list-style: none; }

ul.gallery {
  width: 500px;
  height: 375px;
  position: relative;
  background: transparent url(preview.gif) no-repeat;
}

ul.gallery li {
  float: left;
  font-size: 0.8em;
  display: inline;
  line-height: 1.4em;
  margin-top: 375px;
}

ul.gallery a { padding: 0; }

ul.gallery a span { display: none; padding: 0; }

ul.gallery a:hover { background: none; z-index: 100; }

ul.gallery a:hover span {
  position: absolute;
  width: 500px;
  height: 375px;
  float: left;
  top: 0;
  left: 0;
  display: block;
}

.thumb {
  height: 50px;
  width: 50px;
}

img { border: 0; }

</style>

</head>

<body>

<div class="gallerywrapper">

<div class="title">My Gallery</div>

<ul class="gallery">

<li><a href="#nogo"><img class="thumb" src="img1_thumb.jpg" alt="gallery thumbnail" /><span><img src="img1_large.jpg" alt="gallery image" /></span></a></li>

<li><a href="#nogo"><img class="thumb" src="img2_thumb.jpg" alt="gallery thumbnail" /><span><img src="img2_large.jpg" alt="gallery image" /></span></a></li>

<li><a href="#nogo"><img class="thumb" src="img1_thumb.jpg" alt="gallery thumbnail" /><span><img src="img1_large.jpg" alt="gallery image" /></span></a></li>

<li><a href="#nogo"><img class="thumb" src="img2_thumb.jpg" alt="gallery thumbnail" /><span><img src="img2_large.jpg" alt="gallery image" /></span></a></li>

<li><a href="#nogo"><img class="thumb" src="img1_thumb.jpg" alt="gallery thumbnail" /><span><img src="img1_large.jpg" alt="gallery image" /></span></a></li>

<li><a href="#nogo"><img class="thumb" src="img2_thumb.jpg" alt="gallery thumbnail" /><span><img src="img2_large.jpg" alt="gallery image" /></span></a></li>

<li><a href="#nogo"><img class="thumb" src="img1_thumb.jpg" alt="gallery thumbnail" /><span><img src="img1_large.jpg" alt="gallery image" /></span></a></li>

<li><a href="#nogo"><img class="thumb" src="img2_thumb.jpg" alt="gallery thumbnail" /><span><img src="img2_large.jpg" alt="gallery image" /></span></a></li>

<li><a href="#nogo"><img class="thumb" src="img1_thumb.jpg" alt="gallery thumbnail" /><span><img src="img1_large.jpg" alt="gallery image" /></span></a></li>

<li><a href="#nogo"><img class="thumb" src="img2_thumb.jpg" alt="gallery thumbnail" /><span><img src="img2_large.jpg" alt="gallery image" /></span></a></li>

</ul>

</div>

</body>
</html>

Image CSS Column min-height

Select All and copy to clipboard with <ctrl>+<c>.

#column {
  height: auto !important;
  height: 300px;
  min-height: 300px; /* Must be the same value as height */
}