<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /></head><body style='font-size: 10pt; font-family: Verdana,Geneva,sans-serif'>
<p>Hi Alan,<br />use the validationEngine('validate') function, it returns true or false.<br />Just be careful because it works once while validating, then it returns null.<br />Here's an example of using it after clicking on a normal button: <a href="https://github.com/YetiForceCompany/YetiForceCRM/blob/developer/layouts/basic/modules/Vtiger/resources/List.js#L64">https://github.com/YetiForceCompany/YetiForceCRM/blob/developer/layouts/basic/modules/Vtiger/resources/List.js#L64</a><br />Here's the description: <a href="https://github.com/posabsolute/jQuery-Validation-Engine#actions">https://github.com/posabsolute/jQuery-Validation-Engine#actions</a></p>
<div>---<br />
<p>Z poważaniem / Regards</p>
<div><strong>Mariusz Krzaczkowski</strong></div>
<div><em>Director of Product Development</em></div>
<div>M: +48 884-998-123<br />E: <a title="Mail do Mariusz Krzaczkowski" href="mailto:m.krzaczkowski@yetiforce.com" rel="noreferrer">m.krzaczkowski@yetiforce.com</a></div>
<hr />
<div><span>YetiForce 3.0 LTS has arrived! </span><a href="https://gitdeveloper.yetiforce.com/" rel="noreferrer">Test</a><span> the latest, most innovative open source system in the world, and </span><a href="https://github.com/YetiForceCompany/YetiForceCRM" rel="noreferrer">join</a><span> our community.</span></div>
</div>
<p> </p>
<p>W dniu 2017-01-10 15:01, Alan Lord napisał(a):</p>
<blockquote type="cite" style="padding: 0 0.4em; border-left: #1010ff 2px solid; margin: 0"><!-- html ignored --><!-- head ignored --><!-- meta ignored -->
<div class="pre" style="margin: 0; padding: 0; font-family: monospace">I have quite a complex custom view/page in vtiger where I need the client to populate some fields then click on a button.<br /><br /> When they click on the button the Validation engine runs and the results are displayed in a Popup window if the Validation is good.<br /><br /> However, the only way I can get the Validation to run is to have the button as type="submit". This then ends up triggering a page reload on the original page which I do not want. I have tried various<br /><br /><span style="white-space: nowrap;">form.submit(function(e) {</span><br /><span style="white-space: nowrap;">    e.preventDefault();</span><br /><span style="white-space: nowrap;">});</span><br /><br /><span style="white-space: nowrap;">and trying to</span><br /><br /><span style="white-space: nowrap;">return false;</span><br /><br /><span style="white-space: nowrap;">from the event handler but nothing seems to work.</span><br /><br /> Can anyone think of any examples in the vtiger codebase where the Validation Engine is being used, but without using a button of type submit that I can review for a cluebat?<br /><br /> Cheers<br /><br /> Al<br /><br /><br /><br /><br /> _______________________________________________<br /><span style="white-space: nowrap;"><a href="http://www.vtiger.com/">http://www.vtiger.com/</a></span></div>
</blockquote>
</body></html>