Hello, I''ve wrote an helpers that permits to edit something displayed in a web page, transforming it from being, say, an H2, to be a INPUT inside a FORM. The helpers creates also two button "Save" and "Cancel". It then uses the provided Ajax helpers to save the input data by calling the appropriate controller/action. This is much like the same functionality present on flickr, when you want to add a description to a photo of yours. The helpers consists of a bunch of javascript (with the Prototype coding conventions) and a rails helpers much like the "form_remote_tags" (it''s called inline_edit()) It has been tested to work with Firefox and IE 6.0 I would like to know if and how I could ask to insert this in Rails. Thanks (I do not copy here any code fragments because I don''t know if it''s the right list where this kind of things could be posted) -- Claudio Cicali http://www.flexer.it GPG Keyid: 1024D/555D25CE ''Nos patriae finis et dulcia linquimus arva''
On 6/18/05, Claudio Cicali <c.cicali-dP4/7z9UC85eoWH0uzbU5w@public.gmane.org> wrote:> > Hello, > > I''ve wrote an helpers that permits to edit something > displayed in a web page, transforming it from being, say, > an H2, to be a INPUT inside a FORM. The helpers creates > also two button "Save" and "Cancel". It then uses the > provided Ajax helpers to save the input data by calling > the appropriate controller/action. > > This is much like the same functionality present on > flickr, when you want to add a description to a photo > of yours. > > The helpers consists of a bunch of javascript (with > the Prototype coding conventions) and a rails helpers > much like the "form_remote_tags" (it''s called inline_edit()) > > It has been tested to work with Firefox and IE 6.0 > > I would like to know if and how I could ask to insert > this in Rails. > > Thanks > > (I do not copy here any code fragments because I don''t > know if it''s the right list where this kind of things > could be posted) > > -- > Claudio Cicali > http://www.flexer.it > GPG Keyid: 1024D/555D25CE > ''Nos patriae finis et dulcia linquimus arva'' > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >You can post it here: http://rafb.net/paste/<http://rafb.net/paste/results/23njAU52.html>we can get a look at it that way. Or put it on the rubyonrails.com <http://rubyonrails.com> site. _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
Heath Weaver wrote:> On 6/18/05, Claudio Cicali <c.cicali-dP4/7z9UC85eoWH0uzbU5w@public.gmane.org> wrote: >>I''ve wrote an helpers that permits to edit something >>displayed in a web page, transforming it from being, say, >>an H2, to be a INPUT inside a FORM. The helpers creates >>also two button "Save" and "Cancel". It then uses the >>provided Ajax helpers to save the input data by calling >>the appropriate controller/action. > > You can post it here: > http://rafb.net/paste/Ok, this is what I''ve done so far: http://www.rafb.net/paste/results/EQiQZe64.html Note: the "system" allows (by now) only ONE live instance of an editable object -- Claudio Cicali http://www.flexer.it GPG Keyid: 1024D/555D25CE ''Nos patriae finis et dulcia linquimus arva''
Hi, I am trying to get my head around the RSS code in ruby, does anyone know any pointers for using ruby to parse rss1.0? specifically i want to extract the parts of the rss1.0 file that are in module namespace (ie ev.enddate) Thanks Mark.
> > On 6/18/05, Claudio Cicali <c.cicali-dP4/7z9UC85eoWH0uzbU5w@public.gmane.org> wrote: > >>I''ve wrote an helpers that permits to edit something > >>displayed in a web page, transforming it from being, say, > >>an H2, to be a INPUT inside a FORMThis is a cool idea -- though, there are a few small things you might want to consider. 1. Cancel editing not a button [ Save ] (cancel editing) 2. onmouseover to indicate something is editable 3. you probably want to include some callbacks, like mouseover function (tooltips, yellow highlight) 4. make the font size inside the textarea or input larger, if it was an h2> Note: the "system" allows (by now) only ONE live instance of > an editable objectYou can make multiple instances by using the excellent bind extension. Editation = new class(); Editation = { initialize: function(element) { this.element = element; this.element.onclick = this.clickhandler.bind(this); }, clickhandler: function() { alert(this.element.innerHTML); } } otherwise, a clever idea... personally, I pre-render the form, then hide it with display:none, and just toggle it. that way, I can specify layout and onsubmit actions. <div style=''display:block''> Name: Monkey <a href=''/monkeys/edit/5'' onclick=''return toggle.edit_inplace(this)>(edit)</a> </div> <div style=''display:none''> <form... > <label for=''name''>Name:</label> <input type=''text'' value=''Monkey'' id=''name'' /> <input type=''submit''> <a href='''' onclick=''return toggle.edit_inplace(this);''>(cancel)</a> </div> then my toggle.editinplace works its magic... with regard to putting it in rails, i don''t know about that :) There are additionally quite a few new javascript helpers coming soon. courtenay habtm.com On 6/22/05, Claudio Cicali <c.cicali-dP4/7z9UC85eoWH0uzbU5w@public.gmane.org> wrote:> Heath Weaver wrote: > > On 6/18/05, Claudio Cicali <c.cicali-dP4/7z9UC85eoWH0uzbU5w@public.gmane.org> wrote: > >>I''ve wrote an helpers that permits to edit something > >>displayed in a web page, transforming it from being, say, > >>an H2, to be a INPUT inside a FORM. The helpers creates > >>also two button "Save" and "Cancel". It then uses the > >>provided Ajax helpers to save the input data by calling > >>the appropriate controller/action. > > > > You can post it here: > > http://rafb.net/paste/ > > Ok, this is what I''ve done so far: > > http://www.rafb.net/paste/results/EQiQZe64.html > > Note: the "system" allows (by now) only ONE live instance of > an editable object > > -- > Claudio Cicali > http://www.flexer.it > GPG Keyid: 1024D/555D25CE > ''Nos patriae finis et dulcia linquimus arva''