and there should be nothing wrong with the default changing w/ context -
that is, save whatever the current default is, change it for your context;
restore previous default when done.
There might be something to check into if you want to set a contextual
default when the previous default was not set.... does anyone know if there
is any issue here?
On Tue, Dec 2, 2008 at 8:54 AM, mdipierro <[EMAIL PROTECTED]> wrote:
>
> cynotedb.comment.body.default='hello'
>
> serves two purposes
> 1) prepopultes forms
> 2) sets a default for the field when doing cynotedb.comment.insert
> (...) and the bdy field is missing
>
> On Dec 2, 3:45 am, voltron <[EMAIL PROTECTED]> wrote:
> > This is the way I do things like that
> >
> > you can use Javascript or do it directly in the controller.
> >
> > #Javascript
> >
> > $("#my_textarea").text("Put some text here....");
> >
> > #In the controller:
> >
> > before form.accepts(), assign values, an example:
> >
> > form.components[0].components[1].components[1].components[0].attributes
> > ['requires'][0].error_message = T("Please fill in your email address")
> >
> > I hope that helped
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"web2py Web Framework" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---