Galleria
Ciao
ho un probblema con uno script.
Non funziona, probabilmente dovrei mettere il codice all'interno delle stesso div, ma non è possibbile perchè il riferimento mi serve altrove.
questo è il codice:
questo è il collegamento nel body dove richiamo le immagini
questo è dove lo visualizzo:
vi posto anche il codice intero della pagina
Grazie
elena
Ciao
ho un probblema con uno script.
Non funziona, probabilmente dovrei mettere il codice all'interno delle stesso div, ma non è possibbile perchè il riferimento mi serve altrove.
questo è il codice:
Codice:
codice:<script type="text/javascript" language="javascript">
function showPic (whichpic) {
if (document.getElementById) {
document.getElementById('placeholder').src = whichpic.href;
if (whichpic.title) {
document.getElementById('desc').childNodes[0].nodeValue = whichpic.title;
} else {
document.getElementById('desc').childNodes[0].nodeValue = whichpic.childNodes[0].nodeValue;
}
return false;
} else {
return true;
}
}
</script>
questo è il collegamento nel body dove richiamo le immagini
Codice:
codice:<a onClick="return showPic(this)" href="images/P5230001.JPG" title="immagine1"><img src="images/1-P5230001.jpg"></a>
<a onClick="return showPic(this)" href="images/P5230004.JPG" title="immagine2"><img src="images/1-P5230004.jpg"></a>
<a onClick="return showPic(this)" href="images/P5230008.JPG" title="immagine3"><img src="images/1-P5230008.jpg"></a>
<a onClick="return showPic(this)" href="images/P5230011.JPG" title="immagine3"><img src="images/1-P5230011.jpg"></a>
questo è dove lo visualizzo:
Codice:
codice:<p id="desc"></p>
<img id="placeholder" /><
vi posto anche il codice intero della pagina
Codice:
codice:<script type="text/javascript" language="javascript">
function showPic (whichpic) {
if (document.getElementById) {
document.getElementById('placeholder').src = whichpic.href;
if (whichpic.title) {
document.getElementById('desc').childNodes[0].nodeValue = whichpic.title;
} else {
document.getElementById('desc').childNodes[0].nodeValue = whichpic.childNodes[0].nodeValue;
}
return false;
} else {
return true;
}
}
</script>
</head>
<body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<!-- ImageReady Slices (Senza titolo-1 - Slices: 02) -->
<table width="901" height="526" border="0" align="center" cellpadding="0" class="bordo" cellspacing="0" id="Table_01">
<tr>
<td width="901" height="110"> </td>
</tr>
<tr>
<td align="center" valign="middle" >
</td>
</tr>
<tr>
<td width="901" height="385"><table width="888" height="367" border="0">
<tr>
<td width="116" align="center" valign="top">
<a onClick="return showPic(this)" href="images/P5230001.JPG" title="immagine1"><img src="images/1-P5230001.jpg"></a>
<a onClick="return showPic(this)" href="images/P5230004.JPG" title="immagine2"><img src="images/1-P5230004.jpg"></a>
<a onClick="return showPic(this)" href="images/P5230008.JPG" title="immagine3"><img src="images/1-P5230008.jpg"></a>
<a onClick="return showPic(this)" href="images/P5230011.JPG" title="immagine3"><img src="images/1-P5230011.jpg"></a>
</td>
<td width="405" align="center" valign="top"> </td>
<td width="353" align="center" valign="top">
<p id="desc"></p>
<img id="placeholder" /></td>
</tr>
</table></td>
</tr>
<p><table width="896" border="0">
<tr>
<td height="39" class="galleria1 row_bord">pag. 1 - 20 </td>
<td width="145" class="pagine row_bord">pag. 1,2,3,4,>> </td>
</tr>
</table></p></td>
</tr>
<tr>
<td valign="middle" colspan="2" background="images/last.jpg" height="20" style="color: #652200" align="right">td>
</tr>
</table>
<!-- End ImageReady Slices -->
</body>
Grazie
elena