[jQuery] Tying to make it work...

[jQuery] Tying to make it work...

<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=windows-1255">
<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:st1="urn:schemas-microsoft-com:office:smarttags" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]--><o:SmartTagType
namespaceuri="urn:schemas-microsoft-com:office:smarttags" name="City"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
name="place"/>
<!--[if !mso]>
<style>
st1\:*{behavior:url(#default#ieooui) }
</style>
<![endif]-->
<style>
<!--
/* Font Definitions */
@font-face
{font-family:Wingdings;
panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
{font-family:Calibri;
panose-1:0 0 0 0 0 0 0 0 0 0;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman";}
a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{color:blue;
text-decoration:underline;}
p
{mso-margin-top-alt:auto;
margin-right:0cm;
mso-margin-bottom-alt:auto;
margin-left:0cm;
font-size:12.0pt;
font-family:"Times New Roman";}
span.EmailStyle19
{mso-style-type:personal-reply;
font-family:Arial;
color:navy;}
@page Section1
{size:595.3pt 841.9pt;
margin:72.0pt 90.0pt 72.0pt 90.0pt;}
div.Section1
{page:Section1;}
-->
</style>
</head>
<body lang=EN-US link=blue vlink=blue>
<div class=Section1 dir=RTL>
<p class=MsoNormal dir=LTR><font size=2 color=navy face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:navy'>Thanks for the reply,
I'll try that latter, to see how this performs, by the look of it, it looks
right… </span></font><font size=2 color=navy face=Wingdings><span
style='font-size:10.0pt;font-family:Wingdings;color:navy'>J</span></font><font
size=2 color=navy face=Arial><span style='font-size:10.0pt;font-family:Arial;
color:navy'><o:p></o:p></span></font>
<p class=MsoNormal dir=LTR><font size=2 color=navy face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font>
<p class=MsoNormal dir=LTR><font size=2 color=navy face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:navy'>Thanks.<o:p></o:p></span></font>
<p class=MsoNormal dir=LTR><font size=2 color=navy face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font>
<div>
<p class=MsoNormal dir=LTR><span dir=RTL></span><font size=2 color=navy
face=Arial><span lang=HE dir=RTL style='font-size:10.0pt;font-family:Arial;
color:navy'><span dir=RTL></span> </span></font><font color=navy><span
style='color:navy'><o:p></o:p></span></font>
<div class=MsoNormal align=center dir=LTR style='text-align:center'><font
size=3 color=navy face="Times New Roman"><span style='font-size:12.0pt;
color:navy'>
<hr size=2 width="80%" align=center>
</span></font></div>
</div>
<div align=left dir=ltr>
<table class=MsoNormalTable border=0 cellspacing=0 cellpadding=0 width="100%"
style='width:100.0%;border-collapse:collapse'>
<tr>
<td width="35%" style='width:35.0%;padding:0cm 0cm 0cm 0cm'>
<p class=MsoNormal dir=LTR><font size=1 color="#333333" face=Arial><span
style='font-size:8.0pt;font-family:Arial;color:#333333'>Best Regards,
Eli Sklar, <a href="http://www.k.co.il/">www.K.co.il</a> professional SEO<U5:P></U5:P></span></font><font
color=black><span style='color:black'><o:p></o:p></span></font>
</td>
<td style='padding:0cm 0cm 0cm 0cm'>
<p class=MsoNormal align=center dir=LTR style='text-align:center'><font
size=1 color="#333333" face=Arial><span style='font-size:8.0pt;font-family:
Arial;color:#333333'>050-225-3040 - 03-6500000
<a href="mailto:Eli@k.co.il">Eli@k.co.il</a><U5:P></U5:P></span></font><font
color=black><span style='color:black'><o:p></o:p></span></font>
</td>
<td width="35%" style='width:35.0%;padding:0cm 0cm 0cm 0cm'>
<p class=MsoNormal dir=RTL style='text-align:right;direction:rtl;unicode-bidi:
embed'><font size=1 color="#333333" face=Arial><span lang=HE
style='font-size:8.0pt;font-family:Arial;color:#333333'>בברכה,
אלי סקלאר, <a href="http://www.k.co.il/"><span lang=EN-US dir=LTR>www.K.co.il</span></a><span
dir=RTL></span><span dir=RTL></span> קידום אתרים מקצועי</span></font><font
color=black><span dir=LTR style='color:black'><U5:P></U5:P><o:p></o:p></span></font>
</td>
</tr>
</table>
</div>
<p class=MsoNormal dir=LTR><font size=3 color=navy face=Calibri><span
style='font-size:12.0pt;font-family:Calibri;color:navy'><U5:P> </U5:P></span></font><font
color=black><span style='color:black'><o:p></o:p></span></font>
<p class=MsoNormal dir=RTL style='text-align:right;direction:rtl;unicode-bidi:
embed'><font size=2 color=navy face=Arial><span dir=LTR style='font-size:10.0pt;
font-family:Arial;color:navy'><U5:P> </U5:P></span></font><font
color=navy><span dir=LTR style='color:navy'><o:p></o:p></span></font>
<p class=MsoNormal dir=LTR><font size=2 color=navy face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font>
<div>
<div class=MsoNormal align=center dir=LTR style='text-align:center'><font
size=3 face="Times New Roman"><span style='font-size:12.0pt'>
<hr size=2 width="100%" align=center tabindex=-1>
</span></font></div>
<p class=MsoNormal dir=LTR><b><font size=2 face=Tahoma><span style='font-size:
10.0pt;font-family:Tahoma;font-weight:bold'>From:</span></font></b><font
size=2 face=Tahoma><span style='font-size:10.0pt;font-family:Tahoma'>
discuss-bounces@jquery.com [mailto:discuss-bounces@jquery.com] <b><span
style='font-weight:bold'>On Behalf Of </span></b>John Resig
<b><span style='font-weight:bold'>Sent:</span></b> Tuesday, May 02, 2006 7:00
PM
<b><span style='font-weight:bold'>To:</span></b> jQuery Discussion.
<b><span style='font-weight:bold'>Subject:</span></b> Re: [jQuery] Tying to
make it work...</span></font><o:p></o:p>
</div>
<p class=MsoNormal dir=LTR><font size=3 face="Times New Roman"><span
style='font-size:12.0pt'><o:p> </o:p></span></font>
<p class=MsoNormal dir=LTR style='margin-bottom:12.0pt'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>Eli -
In order to do the on-the-fly Thickbox, like you're doing, it's a little bit
trickier than normal. The problem is that the Thickbox only does the class
check when it first loads (as it should). To do what you want, you'll have to
do something like this:
</span></font><font face="Courier New"><span style='font-family:"Courier New"'>$("#Data")
  .html("...set your html...")
  .find("a.thickbox")
    .each(function(){
      var t = this.title || this.innerHTML ||
this.href;
      TB_show( t, this.href );
    });</span></font>
That should do the trick, let me know if you have any problems with it.
--John
<o:p></o:p>
<div>
<p class=MsoNormal dir=LTR><span class=gmailquote><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>On 4/25/06, <b><span
style='font-weight:bold'>Eli Sklar</span></b> <<a href="mailto:Eli@k.co.il">Eli@k.co.il</a>>
wrote:</span></font></span><o:p></o:p>
<div>
<div>
<p dir=LTR><font size=2 face=Arial><span style='font-size:10.0pt;font-family:
Arial'>Hey guys,
I've found out about <st1:City w:st="on">ajax</st1:City> a few days, and found
jquery while reading a lot of web sites that are related in some way to <st1:City
w:st="on"><st1:place w:st="on">ajax</st1:place></st1:City>.</span></font><o:p></o:p>
<p dir=LTR><font size=2 face=Arial><span style='font-size:10.0pt;font-family:
Arial'> </span></font><o:p></o:p>
<p dir=LTR><font size=2 face=Arial><span style='font-size:10.0pt;font-family:
Arial'>I've been trying to make a small app that is written part in PHP and
part in JS (which I'm new to) using jquery as my base.</span></font><o:p></o:p>
<p dir=LTR><font size=2 face=Arial><span style='font-size:10.0pt;font-family:
Arial'> </span></font><o:p></o:p>
<p dir=LTR><font size=2 face=Arial><span style='font-size:10.0pt;font-family:
Arial'>When I try to add html to a certain span (id=Data) that I have using
$("#Data").html it works fine,</span></font><o:p></o:p>
<p dir=LTR><font size=2 face=Arial><span style='font-size:10.0pt;font-family:
Arial'>But the elements inside (the new one) like links are not working well
with jquery, if I try to implant thickbox (using class="thickbox")
into my code, it just works as a normal link, and disregards the thickbox class
and the jquery code for that class.</span></font><o:p></o:p>
<p dir=LTR><font size=2 face=Arial><span style='font-size:10.0pt;font-family:
Arial'> </span></font><o:p></o:p>
<p dir=LTR><font size=2 face=Arial><span style='font-size:10.0pt;font-family:
Arial'>I've tried to make the elements in the #Data using .add("tr",{class:
"someclass"}).add("a",{href: "image.jpg", class:
"thickbox"}).html("inner text") but it refuses to work, and
only adds the last .add I use and if a have several $("#Data").add
then it only creates the last one, like the pervious onse are deleted or
something…</span></font><o:p></o:p>
<p dir=LTR><font size=2 face=Arial><span style='font-size:10.0pt;font-family:
Arial'> </span></font><o:p></o:p>
<p dir=LTR><font size=2 face=Arial><span style='font-size:10.0pt;font-family:
Arial'>If someone can show me a code that works, I woulkd be more then glad.. </span></font><font
size=2 face=Wingdings><span style='font-size:10.0pt;font-family:Wingdings'>J</span></font><font
size=2 face=Arial><span style='font-size:10.0pt;font-family:Arial'> </span></font><o:p></o:p>
<p dir=LTR><font size=2 face=Arial><span style='font-size:10.0pt;font-family:
Arial'>Thanks a lot guys… </span></font><o:p></o:p>
<p dir=RTL style='text-align:right;direction:rtl;unicode-bidi:embed'><font
size=2 face=Arial><span dir=LTR style='font-size:10.0pt;font-family:Arial'> </span></font><span
dir=LTR><o:p></o:p></span>
<p dir=LTR><span dir=RTL></span><font size=2 color=navy face=Arial><span
lang=HE dir=RTL style='font-size:10.0pt;font-family:Arial;color:navy'><span
dir=RTL></span> </span></font><span lang=HE dir=RTL><o:p></o:p></span>
<div class=MsoNormal align=center dir=LTR style='text-align:center'><font
size=3 face="Times New Roman"><span style='font-size:12.0pt'>
<hr size=2 width="80%" align=center>
</span></font></div>
<div align=left dir=ltr>
<table class=MsoNormalTable border=0 cellspacing=0 cellpadding=0 width="100%"
style='width:100.0%;border-collapse:collapse'>
<tr>
<td width="35%" style='width:35.0%;padding:0cm 0cm 0cm 0cm'>
<p dir=LTR><font size=1 color="#333333" face=Arial><span style='font-size:
8.0pt;font-family:Arial;color:#333333'>Best Regards,
Eli Sklar, <a href="http://www.k.co.il/" target="_blank">www.K.co.il</a>
professional SEO</span></font> <o:p></o:p>
</td>
<td style='padding:0cm 0cm 0cm 0cm'>
<p align=center dir=LTR style='text-align:center'><font size=1 color="#333333"
face=Arial><span style='font-size:8.0pt;font-family:Arial;color:#333333'>050-225-3040
- 03-6500000
<a href="mailto:Eli@k.co.il" target="_blank">Eli@k.co.il</a></span></font><o:p></o:p>
</td>
<td width="35%" style='width:35.0%;padding:0cm 0cm 0cm 0cm'>
<p dir=RTL style='text-align:right;direction:rtl;unicode-bidi:embed'><font
size=1 color="#333333" face=Arial><span lang=HE style='font-size:8.0pt;
font-family:Arial;color:#333333'>בברכה,
אלי סקלאר, <a href="http://www.k.co.il/" target="_blank"><span lang=EN-US
dir=LTR>www.K.co.il</span></a><span dir=RTL></span><span dir=RTL></span>
קידום אתרים מקצועי </span></font><span dir=LTR><o:p></o:p></span>
</td>
</tr>
</table>
</div>
<p dir=LTR><font size=3 face=Calibri><span style='font-size:12.0pt;font-family:
Calibri'> </span></font><o:p></o:p>
<p dir=RTL style='text-align:right;direction:rtl;unicode-bidi:embed'><font
size=2 color=navy face=Arial><span dir=LTR style='font-size:10.0pt;font-family:
Arial;color:navy'> </span></font><span dir=LTR><o:p></o:p></span>
<p dir=RTL style='text-align:right;direction:rtl;unicode-bidi:embed'><font
size=3 face="Times New Roman"><span dir=LTR style='font-size:12.0pt'> </span><span
lang=HE><o:p></o:p></span></font>
</div>
</div>
<p class=MsoNormal dir=LTR style='margin-bottom:12.0pt'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>
_______________________________________________
jQuery mailing list
<a href="mailto:discuss@jquery.com">discuss@jquery.com</a>
<a href="http://jquery.com/discuss/" target="_blank">http://jquery.com/discuss/</a>
</span></font><span lang=HE dir=RTL><o:p></o:p></span>
</div>
<p class=MsoNormal dir=LTR><font size=3 face="Times New Roman"><span
style='font-size:12.0pt'>
<br clear=all>
--
John Resig
<a href="http://ejohn.org/">http://ejohn.org/</a>
<a href="mailto:jeresig@gmail.com">jeresig@gmail.com</a> <o:p></o:p></span></font>
</div>
</body>
</html>
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

















































































































































































































































































    • Topic Participants

    • eli