Validation and upload

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Validation and upload

NizarK
Hello everybody  !!
I have to little problems with my OPS application.

I ve associated validations with fields ... But the validation works only for typing errors and it doesn't work for required fields .. When I submit with a required field missing it works normally like there is not validation associated ..


The second problem is that when i save an xml instance into a database or a file containing an upload field and when i try to reload the instance into a form , the upload field is empty ...

Thanks



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: Validation and upload

Henrik Pettersen
nizarklibi,

can you send us a reproducible example that demonstrate your problems?

Thanks!

Henrik

On 12/14/06, [hidden email] <[hidden email]> wrote:

> Hello everybody  !!
> I have to little problems with my OPS application.
>
> I ve associated validations with fields ... But the validation works only for typing errors and it doesn't work for required fields .. When I submit with a required field missing it works normally like there is not validation associated ..
>
>
> The second problem is that when i save an xml instance into a database or a file containing an upload field and when i try to reload the instance into a form , the upload field is empty ...
>
> Thanks
>
>
>
>
> --
> You receive this message as a subscriber of the [hidden email] mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
>
>
>


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: Validation and upload

Erik Bruchez
Administrator
In reply to this post by NizarK
 > I have to little problems with my OPS application.
 >
 > I ve associated validations with fields ... But the validation works
 > only for typing errors and it doesn't work for required fields
 > .. When I submit with a required field missing it works normally
 > like there is not validation associated ..

This should not happen: required fields that are empty should block
submission. As per the spec: "Any selected instance data node that is
required but empty or found to be invalid stops submission [...]".

Unless, that is, you have xforms:submission/@validate="false".

Can you send a reproducible case of this?

 > The second problem is that when i save an xml instance into a
 > database or a file containing an upload field and when i try to
 > reload the instance into a form , the upload field is empty ...

That's the way the upload control works at the moment: it is strictly
an input control (with the exception of displaying file name,
mediatype and size in the latest builds). If you want to do more, such
as providing a link to the uploaded content, you will need to do some
additional work.

-Erik

--
Orbeon Forms - Web Forms for the Enterprise Done the Right Way
http://www.orbeon.com/




--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws