overload...
rediger disse:
lastpic=5; <- sidste billede der skal vises
pathtosrc="billeder/"; <- sti til billeder
exttopics=".jpg"; <- extension til billeder
current=1; <- billedet du starter ved
...lav en transparent.gif eller en gif men samme baggrund som cellen :)
store billeder navngives som f.eks.: 01s.jpg
hvor 01 refererer til det lille billede :)
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "
http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"><html xmlns="
http://www.w3.org/1999/xhtml" xml:lang="da">
<head>
<meta http-equiv="content-type" content="text/html; charset=iso-8859-1">
<meta name="generator" content="Adobe GoLive" />
<title>Unavngivet side</title>
<style type="text/css">
.galleri{
color: #f90;
font: bold 14px Verdana, Arial, Helvetica, sans-serif
text-decoration: none;
line-height: 14px;
}
.galleri:hover{
color: #c7c7c7;
}
img{border:0px;}
</style>
<script type="text/javascript">
<!--
lastpic=5;
pathtosrc="billeder/";
exttopics=".jpg";
current=1;
ctrlstring="";
function gallery(commandctrl){
if(((current+commandctrl)>0)&&((current+commandctrl)<(lastpic+1))){
current=current+commandctrl;
if(current<10)ctrlstring="0";else ctrlstring="";
document.getElementById("galleri").src=pathtosrc+ctrlstring+current+exttopics;
if(current>1){
document.getElementById("galleriprev").src=pathtosrc+ctrlstring+(current-1)+exttopics;
}else{
document.getElementById("galleriprev").src="transparent.gif";
}
}
}
function biggallery(ctrlcommand){
if(current>1){
if((current+ctrlcommand)<10)ctrlstring="0";else ctrlstring="";
document.getElementById("biggallery").src=pathtosrc+ctrlstring+(current+ctrlcommand)+"s"+exttopics;
}
}
//-->
</script>
</head>
<body>
<table width="450" border="0" cellspacing="0" cellpadding="0" height="400">
<tr>
<td width="350">
<table width="350" border="0" cellspacing="0" cellpadding="0" height="400">
<tr>
<td height="225"><img id="biggallery" src="billeder/01s.jpg" alt="" height="225" width="350"></td>
</tr><tr>
<td height="30"></td>
</tr><tr>
<td height="120">
<table width="350" border="0" cellspacing="0" cellpadding="0" height="120">
<tr>
<td width="160">
<img id="galleriprev" src="billeder/transparent.gif" alt="" name="galleriprev" height="120" width="160" onclick="biggallery(-1);">
</td>
<td width="30"></td>
<td align="center" width="160">
<img id="galleri" src="billeder/01.jpg" alt="" name="galleri" height="120" width="160" onclick="biggallery(0);">
</td>
</tr>
</table>
</td>
</tr><tr>
<td valign="top">
<table width="350" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="160" height="25"></td>
<td width="30" height="25"></td>
<td align="center" valign="middle" width="160" height="25">
<a href="java script: gallery(-1);" class="galleri"><</a>
<a href="java script: gallery(1);" class="galleri">></a>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>