DHTMLX Docs & Samples Explorer

Item Existence

To check whether an item exists, use the isItem method.
Applied to all items.

formdata = [{type: "password", name: 'pass', label: 'Password:'},
             ...];
 
var myForm = new dhtmlXForm("form_container",formData);
var exists = myForm.isItem("pass"); // for radio buttons you must also set the 2nd argument
 
if (exists) 
      {myForm.getItemValue("pass");}

Returns true if the specified item exists.