[jQuery] jqmodal and livequery
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=utf-8">
<META content="MSHTML 6.00.6000.16525" name=GENERATOR></HEAD>
<BODY>
<DIV><SPAN class=000241312-14092007><FONT face=Arial
size=2>hi!</FONT></SPAN></DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial size=2>i have a node that
at some point gets feed via ajax with an image that, when clicked, should launch
itself fullscale inside a jqModal window.</FONT></SPAN></DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial size=2>I thought using
livequery to update the behaviours but i'm puzzled, because jqModal does not
bind itself to the link launching the modal, but to the modal container
itself.</FONT></SPAN></DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial size=2>your help would be
much appreciated.</FONT></SPAN></DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial size=2>here is the code
that i tried:</FONT></SPAN></DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial
size=2> $('a.thickbox').livequery(function(){<BR> $this =
$(this);<BR> $img =
$('img',$this).attr("src");<BR> $('<img
src="'+$img+'"/>').appendTo('#modalWindow');<BR> $('#modalWindow').jqm({trigger:'a.thickbox'});<BR> });</FONT></SPAN></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial size=2>the html
is:</FONT></SPAN></DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=000241312-14092007><FONT face=Arial size=2><p
class="skinBackground" style="margin:auto
0"><BR> <a
href="path/to/image.jpg" title=""
class="thickbox"><BR> <img
src="path/to/image.jpg" style="width:320px"
id="currentImage"/><BR> </a><BR> </FONT></SPAN></DIV>
<P class=MsoNormal><SPAN
style="FONT-SIZE: 7.5pt; COLOR: black; FONT-FAMILY: Verdana">Alexandre
Ple</SPAN></P>
<P class=MsoNormal><SPAN
style="FONT-SIZE: 7.5pt; COLOR: black; FONT-FAMILY: Verdana"></SPAN> </P>
<P class=MsoNormal><SPAN
style="FONT-SIZE: 7.5pt; COLOR: black; FONT-FAMILY: Verdana"></SPAN> </P>
<P class=MsoNormal><SPAN
style="FONT-SIZE: 7.5pt; COLOR: black; FONT-FAMILY: Verdana"><SPAN
class=000241312-14092007>thanks mates!</SPAN></SPAN></P>
<P class=MsoNormal><SPAN
style="FONT-SIZE: 7.5pt; COLOR: black; FONT-FAMILY: Verdana"><SPAN
class=000241312-14092007></SPAN></SPAN> </P>
<P class=MsoNormal><SPAN
style="FONT-SIZE: 7.5pt; COLOR: black; FONT-FAMILY: Verdana"><SPAN
class=000241312-14092007>Alexandre</SPAN></SPAN></P>
<P class=MsoNormal><SPAN
style="FONT-SIZE: 7.5pt; COLOR: black; FONT-FAMILY: Verdana"><SPAN
class=000241312-14092007></SPAN></SPAN> </P></BODY></HTML>
<BR>
<P><FONT SIZE=2>Ce message Envoi est certifié sans virus connu.<BR>
Analyse effectuée par AVG.<BR>
Version: 7.5.485 / Base de données virus: 269.13.18/1007 - Date: 13/09/2007 21:48<BR>
</FONT> </P>