Thanks Antonio,<div><br></div><div>I think it's a good solution but i was looking for a workaround that doesn't change the complete structure of the xsd file, because we already use that xsd in a best part of the project.</div>
<div><br></div><div>I was looking for something like this,</div><div>In validation rules tag we use to do this </div><div><br></div><div><validationrules></div><div> <rule 1....></div><div> <rule 2....></div>
<div> <rule 3....>
</div><div> .</div><div> .</div><div></validationrules> </div><div><br></div><div>and automatically opencms make the logic "AND" of this rules.</div><div>I need something like this</div><div><br>
</div><div><div><validationrules></div><div> <rule ....></div><div> <rule ....></div><div> <rule ....></div><div> (<rule x> or <rule y>)</div><div> .</div><div></validationrules> </div>
<div><br></div><div>I don't know if it's possible to make this kind of rules.</div><div><br></div><div>Thanks again!</div><br><div class="gmail_quote">2012/9/3 Antonio Cordeddu <span dir="ltr"><<a href="mailto:antoniocordeddu@coranto.it" target="_blank">antoniocordeddu@coranto.it</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
<div>Hi Federico,<br>
<br>
in this case I used this workaround: create a nested content with
the fields (Internal, External) and then create a structured
content that calls your nested content using a required field,
like in this example:<div class="im"><br>
<br>
<div><xsd:complexType name="....."></div>
<div><span style="white-space:pre-wrap"> </span><xsd:sequence></div>
</div><div><span style="white-space:pre-wrap"> </span><xsd:element
name="YourName" type="OpenCmsNestedContent" minOccurs="1"
maxOccurs="1" /></div>
<span style="white-space:pre-wrap"></span></xsd:sequence><span style="white-space:pre-wrap"></span>
<div></xsd:complexType></div>
<br>
I hope this help you.<br>
<br>
Kind regards <br>
Antonio<div><div class="h5"><br>
<br>
On 03/09/2012 11.26, federico cacciapuoti wrote:<br>
</div></div></div>
<blockquote type="cite"><div><div class="h5">
<div>Hi to all,</div>
<div><br>
</div>
<div>I'm using opencms 7</div>
<div>I have this situations:</div>
<div><br>
</div>
<div>........</div>
<div>
<div><xsd:complexType name="....."></div>
<div><span style="white-space:pre-wrap"> </span><xsd:sequence></div>
<div><span style="white-space:pre-wrap"> </span><xsd:element
maxOccurs="1" minOccurs="0" name="Internal"
type="OpenCmsVfsFile"/></div>
<div><span style="white-space:pre-wrap"> </span><xsd:element
maxOccurs="1" minOccurs="0" name="External" type="...."/></div>
<div><span style="white-space:pre-wrap"> </span></xsd:sequence></div>
<div><span style="white-space:pre-wrap"> </span></div>
<div></xsd:complexType></div>
......</div>
<div><br>
</div>
<div>I need that al least one of these two fields have to be
required but not both. </div>
<div><br>
</div>
<div>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.</div>
<div><br>
</div>
<div>There is in opencms an option to make this?</div>
<div>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.</div>
<div><br>
</div>
<div>Thanks.</div>
<div><br>
<br>
</div>
<br>
<fieldset></fieldset>
<br>
</div></div><pre>_______________________________________________
This mail is sent to you from the opencms-dev mailing list
To change your list options, or to unsubscribe from the list, please visit
<a href="http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev" target="_blank">http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev</a>
</pre>
</blockquote>
<br>
<pre cols="72">_______________________________________
Coranto informatica di Antonio Cordeddu
Via Torricelli, 9 09047 Selargius (CA)
<a href="mailto:antoniocordeddu@coranto.it" target="_blank">antoniocordeddu@coranto.it</a>
Skype: antonio.cordeddu
<a href="http://www.coranto.it" target="_blank">http://www.coranto.it</a>
___________________________________________</pre>
</div>
<br>_______________________________________________<br>
This mail is sent to you from the opencms-dev mailing list<br>
To change your list options, or to unsubscribe from the list, please visit<br>
<a href="http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev" target="_blank">http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev</a><br>
<br>
<br>
<br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><i style="background-color:rgb(255,255,255)"><font color="#c0c0c0">Federico Cacciapuoti</font></i><br>
</div>