You can tune bootstrap-switch plugin(I used v3.3.2) for your purposes by making little changes (attention - it may cause side effects):
FROM:
$.fn.bootstrapSwitch = function() {
var args, option, ret;
option = arguments[0], args = 2 <= arguments.length ? slice.call(arguments, 1) : [];
ret = this;
this.each(function() {
var $this, data;
$this = $(this);
data = $this.data("bootstrap-switch");
if (!data) {
$this.data("bootstrap-switch", data = new BootstrapSwitch(this, option));
}
if (typeof option === "string") {
return ret = data[option].apply(data, args);
}
});
return ret;
};
TO:
$.fn.bootstrapSwitch = function() {
var args, option, ret;
option = arguments[0], args = 2 <= arguments.length ? slice.call(arguments, 1) : [];
ret = this;
this.each(function() {
var $this, data;
$this = $(this);
data = $this.data("bootstrap-switch");
if (!data) {
$this.data("bootstrap-switch", data = new BootstrapSwitch(this, option));
}
if (typeof option === "string") {
//this section was modified (start)!
var temp = data[option].apply(data, args);
return ret = option == 'state' ? data[temp ? 'onText' : 'offText'].apply(data, args) : temp;
//this section was modified (end)!
}
});
return ret;
};
IMPLEMENTATION:
var res = $('#mycheckbox').bootstrapSwitch('state');
//res == 'Enable' or 'Disable'
P.S. if you will use it only once, you can simply do this (without doing any changes in plugin):
var element = $('#mycheckbox');
var res = element.bootstrapSwitch(element.bootstrapSwitch('state') ? 'onText' : 'offText');