Ciao a tutti sto cercando di usare Jquery per avere due effetti in una pagina aspx. Il primo è l'effetto CYCLE sulla testata (che funziona bene) il secondo è una galleria fotografico con lightbox che va in errore. Compilando mi viene restituito l'errore "Proprietà o metodo non supportati dall'oggetto" in corrispondenza della riga $('#gallery a').lightBox(); dello script:
<script type="text/javascript">
$(function() {
$('#gallery a').lightBox();
});
</script>
Grazie in anticipo
Di seguito la sezione HEAD della Page master:
<head><title>
Gelato al cioccolato, un'oasi di freschezza!!
</title><link href="StyleSheet.css" rel="stylesheet" type="text/css" /><link rel="shortcut icon" type="image/vnd.microsoft.icon" href="immagini/favicon.ico" /><link href="jquery.lightbox-0.5.css" rel="stylesheet" type="text/css" />
<script src="js/jquery.js" type="text/javascript"></script>
<script src="js/jquery.lightbox-0.5.js" type="text/javascript"></script>
InsidePage.master
<script src="js/jquery.lightbox-0.5.pack.js" type="text/javascript"></script>
<script src="js/jquery.lightbox-0.5.min.js" type="text/javascript"></script>
<script src="js/jquery.js" type="text/javascript"></script>
<script type="text/javascript">
$(function() {
$('#gallery a').lightBox();
});
</script>
<style type="text/css">
/* jQuery lightBox plugin - Gallery style */
#gallery {
background-color: #444;
padding: 10px;
width: 520px;
}
#gallery ul { list-style: none; }
#gallery ul li { display: inline; }
#gallery ul img {
border: 5px solid #3e3e3e;
border-width: 5px 5px 20px;
}
#gallery ul a:hover img {
border: 5px solid #fff;
border-width: 5px 5px 20px;
color: #fff;
}
#gallery ul a:hover { color: #fff; }
</style>
<style type="text/css">
.slideshow { height: 68; width: 200px; margin: 0}
</style>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.1/jquery.min.js"></script>
<script type="text/javascript" src="http://cloud.github.com/downloads/malsup/cycle/jquery.cycle.all.2.74.js"></script>
<script type="text/javascript">
$(document).ready(function() {
$('.slideshow').cycle({
fx: 'fade' // choose your transition type, ex: fade, scrollUp, shuffle, etc...
});
});
</script>
Di seguito il codice nella pagina aspx:
<div id="gallery" style="text-align:left">
<aspataList ID="Repeater1" RepeatColumns="3" RepeatDirection="Horizontal" runat="server">
<HeaderTemplate><table width="250" height="250"><tr></HeaderTemplate>
<ItemTemplate>
<td width="300" height="300">
<table>
<tr><td>
<div >[img]<%# "immagini/" & DataBinder.Eval(Container.DataItem, "descriImg")%>[/img]</div>
</td></tr>
<tr><td><%#DataBinder.Eval(Container.DataItem, "didascalia")%></td></tr>
</table>
</ItemTemplate>
<FooterTemplate> </td></tr><tr><td>Indietro</td></tr></table></FooterTemplate>
</aspataList>
</div>