[haml] Creating a button to change contents of text field

2011-08-23 Thread Wuffers Lightwolf
Here is what I want to achieve: There is a text field that the user inserts text into. There is a button for doing an action on that text. The user presses the button, and the content of the text field is updated via a Ruby method. Does anyone know if this is possible with HAML? Thanks in adva

Re: [haml] Creating a button to change contents of text field

2011-08-24 Thread Mark Szymanski
Something I should probably add: I'm doing this with Sinatra, not Rails. On Tuesday, August 23, 2011 at 9:34 PM, Wuffers Lightwolf wrote: > Here is what I want to achieve: > > There is a text field that the user inserts text into. > > There is a button for doing an action on that text. > >

Re: [haml] Creating a button to change contents of text field

2011-08-24 Thread Nate Vack
On Tue, Aug 23, 2011 at 9:34 PM, Wuffers Lightwolf wrote: > Here is what I want to achieve: > > There is a text field that the user inserts text into. > > There is a button for doing an action on that text. > > The user presses the button, and the content of the text field is > updated via a Ruby

Re: [haml] Creating a button to change contents of text field

2011-08-24 Thread Mark Szymanski
So there's no way that I can do this in Ruby? On Wednesday, August 24, 2011 at 8:20 PM, Nate Vack wrote: > On Tue, Aug 23, 2011 at 9:34 PM, Wuffers Lightwolf (mailto:mrman...@me.com)> wrote: > > Here is what I want to achieve: > > > > There is a text field that the user inserts text into. > >

Re: [haml] Creating a button to change contents of text field

2011-08-24 Thread Nate Vack
On Wed, Aug 24, 2011 at 8:21 PM, Mark Szymanski wrote: > So there's no way that I can do this in Ruby? If you want to re-render the form, you can -- just set the :value parameter for your input element. But really, it's not the kind of thing that's haml-related. If it works in ERB, it'll work in

Re: [haml] Creating a button to change contents of text field

2011-08-24 Thread Mark Szymanski
Ok, thanks. On Wednesday, August 24, 2011 at 8:48 PM, Nate Vack wrote: > On Wed, Aug 24, 2011 at 8:21 PM, Mark Szymanski (mailto:mrman...@me.com)> wrote: > > So there's no way that I can do this in Ruby? > > If you want to re-render the form, you can -- just set the :value > parameter for yo