Sorry for the delay. Your Solution works fine for me.
Thanks a lot
On 25 fév, 05:41, DenesL wrote:
> What do you mean?
> SQLFORM is a FORM so you can pass **attributes.
>
> form=SQLFORM(db.person,_id='myid')
>
> On Feb 24, 10:56 pm, Thadeus Burgess wrote:
>
>
>
> > and for the record SQLFORM fr
What do you mean?
SQLFORM is a FORM so you can pass **attributes.
form=SQLFORM(db.person,_id='myid')
On Feb 24, 10:56 pm, Thadeus Burgess wrote:
> and for the record SQLFORM freaking rocks. It just needs to be
> redesigned with customization in mind.
>
> -Thadeus
>
> On Wed, Feb 24, 2010 at 9:5
and for the record SQLFORM freaking rocks. It just needs to be
redesigned with customization in mind.
-Thadeus
On Wed, Feb 24, 2010 at 9:55 PM, Thadeus Burgess wrote:
> And hence the inherent flaw in SQLFORM :)
>
> Though I can't complain since I have not devoted time to redesigning
> the sy
And hence the inherent flaw in SQLFORM :)
Though I can't complain since I have not devoted time to redesigning
the system as I so very much would like to do.
-Thadeus
On Wed, Feb 24, 2010 at 9:48 PM, DenesL wrote:
> The id is only one case.
> You would have to recreate the whole thing to be
The id is only one case.
You would have to recreate the whole thing to be sure everything is
updated but that makes it slower.
Ideally you would do these things at form creation or by setting
defaults beforehand ala field defaults.
Doing it at form creation means allowing **attributes in any funct
You are right. Perhaps it should be re-initialized inside accept? What
do you think?
On Feb 24, 9:38 am, DenesL wrote:
> The problem is that form.custom.begin is evaluated when the form is
> created.
> Changing '_id' after it has been created does not recalculate
> form.custom.begin, but you can
The problem is that form.custom.begin is evaluated when the form is
created.
Changing '_id' after it has been created does not recalculate
form.custom.begin, but you can do so manually:
form['_id']='my_form_id'
form.custom.begin=XML("<%s %s>") %(form.tag,form._xml()[0]))
Denes.
On Feb 24, 9:50
Massimo,
no misundestood. I expect a css ID in my form.
I have run the same test on welcome app. That's work fine.
But in my app, no ID for my form.
It's perhaps a "bug" in view with the tag {{=form.custom.begin}}.
On 24 fév, 01:10, mdipierro wrote:
> It does work:
>
> $ python web2py.py -S w
It does work:
$ python web2py.py -S welcome -M
>>> form=auth.register()
>>> form['_id'] = 'my_form_id'
>>> print form.xml()
perhaps I misunderstood the question and you expect something
different?
On Feb 23, 2:07 pm, arnaud wrote:
> Thanks Massimo, but this code has no effect. No ID is s
Thanks Massimo, but this code has no effect. No ID is set to form.
SQLform is maybe the good solution.
On 23 fév, 07:50, mdipierro wrote:
> def register():
> form=auth.register()
> form['_id'] = 'my_form_id'
> return dict(form=form)
>
> On Feb 22, 2:09 pm, arnaud wrote:
>
>
>
> > Hi Mas
def register():
form=auth.register()
form['_id'] = 'my_form_id'
return dict(form=form)
On Feb 22, 2:09 pm, arnaud wrote:
> Hi Massimo,
>
> when I test your code (platform : windows / web2py 1-754), it's return
> the following error :
>
> Traceback (most recent call last):
> File "gluon
Sorry by bad
def register():
form=auth.registe()
form['_id'] = 'my_form_id'
return dict(form=form)
On Feb 22, 2:09 pm, arnaud wrote:
> Hi Massimo,
>
> when I test your code (platform : windows / web2py 1-754), it's return
> the following error :
>
> Traceback (most recent call last):
>
Hi Massimo,
when I test your code (platform : windows / web2py 1-754), it's return
the following error :
Traceback (most recent call last):
File "gluon/restricted.py", line 173, in restricted
File "C:/dev/web2py1754/applications/sites/controllers/user.py",
line 21, in
File "gluon/globals.p
It is the same
def register():
form=auth.register_form()
form['_id'] = 'my_form_id'
return dict(form=form)
On Feb 19, 11:42 am, Thadeus Burgess wrote:
> Yes but with crud, or in his case auth.register_form()
>
> -Thadeus
>
> On Fri, Feb 19, 2010 at 11:31 AM, mdipierro wrote:
> > aha
>
Yes but with crud, or in his case auth.register_form()
-Thadeus
On Fri, Feb 19, 2010 at 11:31 AM, mdipierro wrote:
> aha
>
> form=SQLFORM(.,_id='thisformid')
>
> or
>
> form['_id'] = 'thisformid'
>
> the latter works with crud forms too. Remember that
>
> class SQLFORM(FORM): ... is a he
aha
form=SQLFORM(.,_id='thisformid')
or
form['_id'] = 'thisformid'
the latter works with crud forms too. Remember that
class SQLFORM(FORM): ... is a helper.
On Feb 19, 11:03 am, Thadeus Burgess wrote:
> he wants a HTML CSS id on the form.
>
> -Thadeus
>
> On Fri, Feb 19, 2010 at 6:41 AM,
he wants a HTML CSS id on the form.
-Thadeus
On Fri, Feb 19, 2010 at 6:41 AM, mdipierro wrote:
> What do you mean by setting an ID?
>
> On Feb 19, 2:05 am, arnaud wrote:
>> Hi,
>> I'm newbie with python and Web2Py. My problem : I want customize my
>> register form.
>>
>> This is my code
>
What do you mean by setting an ID?
On Feb 19, 2:05 am, arnaud wrote:
> Hi,
> I'm newbie with python and Web2Py. My problem : I want customize my
> register form.
>
> This is my code
>
> #model
> auth_table = db.define_table(auth.settings.table_user_name,
> Field('first_name', length=128, defa
18 matches
Mail list logo