[opencms-dev] make required one of two fields

federico cacciapuoti fe.cacciapuoti at gmail.com
Mon Sep 3 11:26:05 CEST 2012


Hi to all,

I'm using opencms 7
I have this situations:

........
<xsd:complexType name=".....">
<xsd:sequence>
<xsd:element maxOccurs="1" minOccurs="0" name="Internal"
type="OpenCmsVfsFile"/>
<xsd:element maxOccurs="1" minOccurs="0" name="External" type="...."/>
</xsd:sequence>
</xsd:complexType>
......

I need that al least one of these two fields have to be required but not
both.

So in the workplace I can't save the changes to an "object" if I don't fill
at least one of the two fields.

There is in opencms an option to make this?
I was thinking to do that, using a regular expression, but i don't know if
I can recover the fields and use them in <validationrules> tag.

Thanks.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20120903/96a8b1e3/attachment.htm>


More information about the opencms-dev mailing list