On Wednesday 01 October 2003 1:05 pm, Oscar Rambla wrote: > On Sunday 28 September 2003 08:45, Mark Bucciarelli wrote: > > since you can compose an HTML page with multiple forms, it should be > > possible with quixote as well. i suspect this would greatly improve the > > propects for code reuse in quixote apps. > > I can give you my opinion. > > Quixote framework relies heavily on the form instances as the recipient and > handler of all request. This behaviour is simple, coherent and generic > enough to fit well for most of quixote users. Agreed. I really enjoy devloping with Quixote and find it suits my needs extremely well. > If this is not your case, you may need to construct another structure to > receive requests prior to form handlers and to render them as a page. > (This can be harder work than it sounds.) I'll take a crack at it, if I get motivated enough. I don't think it will be that hard. I would probably start with a login widget, which would require an url as an __init__ parameter. The widgets default behavior is to require both fields. If you add that widget to your Quixote form, and someone clicks the login button, the process() and action() methods (of an enhanced form class) will trigger this widgets process() and action() methods; that is, if both fields are not entered, then display a hint and re-render the form. Otherwise, load the user/pass into the session object, and go to the url specified in the init. As a user of that component, you need to do set up session, and pass init the widget with the url, and write the logic to handle the user/pass parameters. This is a trivial example because it doesn't save _that much_ time, but hopefully it's a bit clearer explanation of my idea. Regards, Mark