It would be tricky because form.custom.begin is not like the form.custom
widgets, which are just references to HTML helper objects within the form
object (so it's easy to add attributes). It cannot be a helper object
because it only represents the opening <form> tag, not the complete HTML
form element (which would include the closing tag and all the contents
within).
Anthony
On Saturday, May 12, 2012 11:37:23 PM UTC-4, Matt wrote:
>
> Hi there,
>
> Potential change / improvement to SQLFORM.
>
> At present when you do the following:
>
> def user():
> form = auth()
> form['_class'] = 'mystyle'
>
> return dict(form = form)
>
> user.html
>
> {{= form.custom.begin }}
>
> You get the following output:
>
> <form action="" enctype="multipart/form-data" method="post">
>
> Is it possible to amend this so that the class is output also?
>
> Thanks in advance,
> Matt
>