[jQuery] Re: Listbox values > text box

2007-09-24 Thread Diddly Doo
Yeah, I'm trying to add all the values from the listbox to the hidden box. The box is type="hidden". I think we need some kind of loop possibly to get all the values.

[jQuery] Re: Listbox values > text box

2007-09-11 Thread Dylan Verheul
On 9/11/07, Joan Piedra <[EMAIL PROTECTED]> wrote: > Dylan, > That's a nice workaround, to just pass the selected value. But I think > Diddly needs to add all the values in #foo2. Hmm, you could be right, but I wouldn't use JavaScript for that. Since you know all values when you build the page, y

[jQuery] Re: Listbox values > text box

2007-09-11 Thread Joan Piedra
Dylan, That's a nice workaround, to just pass the selected value. But I think Diddly needs to add all the values in #foo2. Diddly, I think you mistype this, shouldn't it be type="hidden"? On 9/11/07, Dylan Verheul <[EMAIL PROTECTED]> wrote: > > > Try this: > > $('#theButton2').click(function()

[jQuery] Re: Listbox values > text box

2007-09-11 Thread Dylan Verheul
Try this: $('#theButton2').click(function() { $("#foo2").val($("#foo").val().toString()); }); You catch the click event. You set the value of the text box to the value of the select (converted to a string). -Dylan On 9/10/07, Diddly Doo <[EMAIL PROTECTED]> wrote: > > I've some HTML as below