MToggle
The MToggle component is a switch button. It can be switched (on and off) either by clicking it or by toggling it.
Contents
Usage
Get the Current Value
You can get the current value from PHP with $this->MToggle1->Items[$this->MToggle1->ItemIndex];
.
From JavaScript use $("#ComponentName_outer a").attr("aria-valuenow");
.
Client-side Features
DOM Elements
The component generates the following client-side DOM elements:
- Wrapper (HTMLDivElement). Full web browser support. Access it with
$("#ComponentName_outer").get()[0]
.- Main element (HTMLSelectElement). Full web browser support. Access it with:
$("#ComponentName").get()[0]
.- On (HTMLOptionElement). Full web browser support. Access it with:
$("#ComponentName option[value='1']").get()[0]
. - Off (HTMLOptionElement). Full web browser support. Access it with:
$("#ComponentName option[value='0']").get()[0]
.
- On (HTMLOptionElement). Full web browser support. Access it with:
- Main element (HTMLSelectElement). Full web browser support. Access it with:
Client-side Events
- Documented in the RPCL Reference.
Server-side Features
Properties, Methods and Events
- Documented in the RPCL Reference.