Moving from scriptalicious to jquery, show/hide effect on link in asp.net repeater -
In my blog, I have a repeater in which the actual blog and comments from that blog are now on the comments with Scriptalicious I use a show / hidden effect but now I want to convert it to Jquery but I have some problems. It seems that I have to destroy a jquery script for every divi, which is going on for this effect is?
This is html, where the link to show / hide comments is today (scriptwriter):
, {duration: 1}); return back;" & gt; Show Comments (& lt;% # Counments (Databender.Aval (Container, "DataItimId"))%>) & lt; / A & gt; | & Lt; A href = "#" onclick = "Fade ('i & lt;% # Eval (" id ")% & gt;', {duration: 0.5}); return back;; & gt; hide comments & Lt; / a & gt;; As you can see, I am using: onclick = "new effect.fade ('i & lt;% # Eval ("id")%> New effect. Fade is passing in id. Can someone give me this hint how can I do this with Zacry? < P> UPDATE is now working, code from acceptable answer, and made some small adjustments. I do, he looks like this:
& lt; a href = "javascript: zero (0);" title = "i" & lt;% # Eval ("id") % & Gt; "& gt; Vis Cometter (& lt;% # Counments (Databender.Aval (Container," DataItim.ID "))%> & lt; / a & gt;
& lt; div id = "i & lt;% # Eval (" id ")% & amp; Gt; "Style =" Display: None; "& gt; & lt;% # GetComments (DataBinder.Eval (Container," DataItem.id "))% & gt; & Lt; / Div & gt; And Jquery function for magic:
& lt; Script type = "text / javascript" & gt; $ (Document) .ready (function () {$ ("a: contains')"). Click (Fun Ction () {$ id = $ (this) .attr ('title'); $ ('#' + $ Id + ''). Show (); Details are False;})});
Thanks for the help! :)
Do you mean something like that?
$ ("A: In (Show 'Comments')"). Click (function () {$ id = $ (this) .attr ('id'); $ ('#' + id + '') .show ();});
Comments
Post a Comment