<div dir="ltr">Thanks Tobias, It worked.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jul 21, 2015 at 2:00 PM, Tobias Karrer <span dir="ltr"><<a href="mailto:kartobi@gmail.com" target="_blank">kartobi@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div text="#000000" bgcolor="#FFFFFF">
<div>Hi Ashish,<br>
<br>
you need to move the validation rule for your nested element to
the included .xsd, so in the same file where <xsd:element
name="Text" type="OpenCmsString" /> is defined.<br>
<br>
Best,<br>
Tobias<div><div class="h5"><br>
<br>
Am 21.07.2015 um 08:01 schrieb Ashish Shekhar:<br>
</div></div></div>
<blockquote type="cite">
<pre><div><div class="h5"> Hi,
I am setting validation rule for elements which are under tab.
One tab contains Nested elements for which I am trying to set the
validation rule.
Validation are working fine for all elements under tab but validation for
element for nested is not working.
The default value for the nested element is working fine but validation
seems not working.
Can you please help on this? What could be the issue?
<resourcebundle name="my.template.workplace" />
<tabs>
<tab element="Heading" collapse="false" name="General" />
<tab element="Author" collapse="false" name="Author" />
<tab element="SubMainContent" collapse="true"
name="SubMain" />
</tabs>
<defaults>
<default element="SubMainContent/Title"
value="%(key.title.oceanofsky)</div></div>" />
</defaults>
<validationrules>
<rule element="Heading" regex=".+" type="error"
message="heading must not be empty." />
<rule element="Author" regex="\w{3,}.{0,}" type="error"
message="Author name must start with at least 3 characters."/>
<rule element="SubMainContent/Text" regex=".+" type="error"
message="heading must not be empty." />
</validationrules>
-Ashish
_______________________________________________
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>
</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" rel="noreferrer" target="_blank">http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev</a><br>
<br>
<br>
<br>
<br></blockquote></div><br></div>