Saturday, July 18, 2009

SugarCRM

One of my clients is implementing an instance of SugarCRM - the recently setup several webToLead forms and wanted to require a set of fields other than the default. After poking around a little (on the documentation) I took a look at the page source. The solution proved quite simple.

<input id="req_id" name="req_id" value="first_name; last_name;webtolead_email1;" type="hidden">

As you can see - adding new id entries to the value of this field makes those fields required.
P.S. name and id appear to be set the same on every field - but the javascript appears to be using the id for verification.