Called when user clicks form's button.
action(action, [event])

action | string, name of the action (name of the button)
event | object, DOM Event Object (optional)

Returns undefined.

#### Description

The first argument action is the name of the action (name of the button). The second argument event is DOM event object. This method does not do anything besides calling appropriate action handler from the .actions object and triggering .onAction event. When form initializes it adds action on click event to all buttons in the form.
If you have form defined in the following way: $('#form').w2form({ name : 'form', formURL : '/server/path', fields: [ { name: 'first_name', type: 'text', required: true }, { name: 'last_name', type: 'text', required: true }, { name: 'email', type: 'email' } ], actions: { "save": function (target, data) { this.validate(); }, "reset": function (target, data) { this.clear(); } } }); You can do: w2ui['form'].action('reset');