Seems I'm missing something important here...
I want to have a conditonal validation:
[[!formIt?
....
&validate=`spam:blank,
attachment:required`
]]
The attachment:required part should be flexible depending on the condition if [[+fi.uid]] was set or not.
So far I tried the following things:
&validate=`spam:blank,
[[+fi.uid:notempty=``:default=`attachment:required`]]
`
]]
I also tried it uncached
&validate=`spam:blank,
[[!+fi.uid:notempty=``:default=`attachment:required`]]
`
]]
Putting the whole validation in two chunks and loading them conditionally also did not help.
[[!+fi.uid:notempty=`[[$val_not_required]]`:default=`[[$val_required]]`]]
(cached AND uncached).
I always end up with the required result.
I'm sure that [[+fi.uid]] is available, so what is going wrong here?
Kind regards,
pepebe
[ed. note: pepebe last edited this post 11 years, 1 month ago.]