Action address in HTML forms

the hatter at
Tue Mar 3 17:48:40 GMT 2009

On Tue, 3 Mar 2009, Nigel Peck wrote:

> Zbigniew Lukasiak wrote:

> > Is it then a reasonable rule when writing a 'high level web
> > library/framework' to restrict the forms to always submit to their own
> > address?
> Have you considered the case where the initial form is on a page, and
> then submits to a script, which keeps calling itself from there?
> e.g.
> has a search form on it, which points to:

I'm most likely to incorporate contact.html into in that case -
it makes it easier to keep any changes in sync between the views if both
options load the same template.  Called with no parameters, it shows the
page unfilled; called with incorrect parameters it shows the page,
regexping in previous correct data and error messages; submitted with
correct data it does something potentially more exciting.

I'd expect most frameworks to remove the URI distintion between html pages
and where scripts can execute, so /contact could equally be a plain page
or a script.

the hatter

More information about the mailing list