关于mobilesroll使用方法的再次声明

js

$('#name').click(function(valueText) {
$('#demo').mobiscroll('show');
// return false;
});
$("#demo").mobiscroll('valueText').select({
theme: "android-ics light",
display: 'bottom',
lang: "zh",
// cancelText: null,
headerText: function(valueText) {
return "客户名称"
},
defaultValue: "请选择",
formatResult: function(array) {
$('.changetxt').text('请选择');
},
onSelect: function (valueText, inst) {
$('.v-show').show();
$('.v-hide').hide();
var dtxt=$('#demo>option:selected').text();
$('.changetxt').text(dtxt);
// $('.changetxt').prepend($('#demo>option').eq(array).text());
},
});

原文地址:https://www.cnblogs.com/zhouyx/p/7601018.html