How about?
{{c,w=form.custom,form.custom.widget}}
{{c.begin}}
{{=w.field1}}
{{=w.field2}}
{{=w.field3}}
{{=w.field4}}
{{c.submit}}
{{c.end}}
On Saturday, 19 October 2013 17:41:48 UTC-5, Ramos wrote:
>
> ok, sorry i missed it but as we have to write
>
> {{=form.custom.begin}} in the beggining and
>
> {{=form.custom.end}} in the end.
>
>
> it seems that having to write form.custom.widget. for every field seems like
> a lot of typing
>
>
> couldnt it be ommited?
>
>
>
>
>
>
>
>
>
> 2013/10/19 Massimo Di Pierro <[email protected] <javascript:>>
>
>> But a form in html
>>
>> does not just contain <input/>. It also needs <form> and </form>.
>>
>>
>> On Saturday, 19 October 2013 16:19:45 UTC-5, Ramos wrote:
>>>
>>> hello, custom forms in web2py are very verbose in my opinion
>>>
>>> Is that really necessary?
>>>
>>> If i pass the form from my controller to my view i should only have to
>>> write
>>>
>>> {{=form.custom.widget.last_**name}} somewhere in the view
>>>
>>>
>>>
>>>
>>> without having to write also
>>>
>>>
>>>
>>> {{=form.custom.begin}} in the beggining and
>>>
>>> {{=form.custom.end}} in the end.
>>>
>>>
>>>
>>> I´d like to know why and why not simpler
>>>
>>>
>>> for example my stupid idea
>>>
>>>
>>> <div form-custom>
>>>
>>>
>>> {{widget.first_name}}
>>>
>>>
>>> {{widget.last_name}}
>>>
>>> </div>
>>>
>>>
>>> Thank you
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> --
>> Resources:
>> - http://web2py.com
>> - http://web2py.com/book (Documentation)
>> - http://github.com/web2py/web2py (Source code)
>> - https://code.google.com/p/web2py/issues/list (Report Issues)
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "web2py-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected] <javascript:>.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>
>
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.