<baseform>
web form

JavaScript: lz.baseform
extends <view> » <node> » lz.Eventable »

The <baseform> tag allows you to create a web form. The data represented by components that are enclosed in the form tag can be sent to the server using the <submit> tag. Each form component, such as <checkbox>, <combobox> or <radiogroup> must have a name. The data is submitted as name-value pairs, using the name and value of the component.

baseform provides no layout for its contents. If you want a simple automatic form layout use the <form> tag.

See Also:

Attributes

Name (CSS property) Type (tag) Type (js) Default Category
changed expression any false read/write
  Boolean to determine whether the baseformitem was changed.
formdata expression any   read/write
  Holds a reference to each datacomponent contained within the form.

Methods

addFormItem()
baseform.addFormItem(item);
Parameter Name Type Description
item    

commit()
baseform.commit();
Commits baseform's baseformitem values and sets baseform and baseformitems to changed=false.

removeFormItem()
baseform.removeFormItem(item);
Parameter Name Type Description
item    

rollback()
baseform.rollback();
Rollback baseform's baseformitem values and sets baseform and baseformitems to changed=false.

setChanged()
baseform.setChanged(changed : Boolean, skipformdata : Boolean);
Setter to to set baseform's status to changed. Baseformitems should set baseform's changed to true when its values change and set baseform's changed to false when its values are rollback or committed.
Parameter Name Type Description
changed Boolean true if changed, else false.
skipformdata Boolean if true, set formdata changed values, else don't.

Methods inherited from lz.Eventable

destroy, setAttribute

Events

Name Description
onchanged Event sent when baseformitem is changed. Only sent once when true or once when false.

Events inherited from <node>

onconstruct, ondata, oninit

Events inherited from lz.Eventable

ondestroy