Re: serializing elements via $$

Travis
2008-06-24T15:26:50Z

Okay, this seems to work.  I''m not sure if its the most effective way
though.



        <script type="text/javascript"
src="prototype.js">






Input 1
Input 2
Input 3





                            <input class="row_data"
type="text"
name="data[item][0]" value="abc1" />


                            <input class="row_data"
type="text"
name="data[item][1]" value="abc2" />


                            <input class="row_data"
type="text"
name="data[item][2]" value="abc3" />


                            <a href="#" onclick="getRow($
(''row_1''));">Serialize Row




                            <input class="row_data"
type="text"
name="data[item][0]" value="abc4" />


                            <input class="row_data"
type="text"
name="data[item][1]" value="abc5" />


                            <input class="row_data"
type="text"
name="data[item][2]" value="abc6" />


                            <a href="#" onclick="getRow($
(''row_2''));">Serialize Row






            getRow = function(row) {
                alert(Form.serializeElements($(row).descendants()));
            }




On Jun 24, 8:48 am, Travis
<Travis.Pax...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:
> Is it at all possible to serialize only elements on a form using the $
> $ selector?
>
> For example:
>
> ...
>
>
>
>
>
>
>
>
>
>
>
>
> ...
>
> And then using prototype to serialize each row: