I'm going to give the disclaimer that i can't make much sense out of the example you've posted. You're referencing 'comment-form' and 'comment_parent_id' which are nowhere to be found in the actual HTML. The facts that I am going to assume are...
A) That you're inserting a form element inside of an element B) That you want this object to 'fade in' when its been inserted C) That you're re-using the same object over and over. IE, you're not using the form-placeholder as a clone-able object that gets copied and injected into the DOM in multiple places. D) That you're using the overzealous, BS JS that is jQuery and you've come here looking for a hand out. You'll need in conjunction with Prototype, the scriptaculous library which is what is used for the Effects library. Element.addMethods({ fade : function(element, config){ return new Effect.Fade(element, config); }, appear : function(element, config){ return new Effect.Appear(element, config); } }); var myFunc = function(){ $('container').appendChild($('form-container')).setOpacity(0).appear ({ duration : 6}); }; -- http://positionabsolute.net On Sep 24, 9:58 am, Владимир Хомич <khomich.v...@gmail.com> wrote: > Hi everybody! > could someone please help to rewrite this function to prototype? > $('#comment-form') > .hide() > .appendTo('#comment-10 .form-placeholder') > .fadeToggle(600); > $('#comment_parent_id').val(1); > > <div id="comment-10"> > <span id="commenter">Neverhood</span><span id="comment-date"> > (September 23, 2009 at 11:44 PM)</span><br> > ye > <div class="form-placeholder"></div> > </div> --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Prototype & script.aculo.us" group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~----------~----~----~----~------~----~------~--~---