[pmwiki-users] Fox forms and form validation

Hans design5 at softflow.co.uk
Wed Jul 16 02:59:57 CDT 2008


Wednesday, July 16, 2008, 6:24:04 AM, Scott Smith wrote:

> For example, I type in 'destination': San Diego/2008. The slash is invalid
> and the validation mark-up catches it and re-displays the form. The
> 'destination' field is now blank. This doesn't happen with my other fields
> that have validation. They come back with the failed value (which is what I
> want and expect).

the reason is that the input field named 'destination' has a value
which prevents it being set by the previous request:

(:input text destination "{$:destination}" size=40:)

change to (:input text destination size=40:) and it works.

you don't seem to use a {$:destination} page text variable on the
target page anywhere.

In fact the other fields like (:input text name=$:traveler2 size=40:)
don't load their input value  from a PTV either I think, in which
case you could use (:input text traveler2 size=40:) instead.
(unless you use this form as a edit form as well, but it does not
appear as such)

  ~Hans




More information about the pmwiki-users mailing list