感谢您的回复。
1. keypress event works, but I am not able to remove the cursor also from the multiselect. As per the requirement, even the cursor(text input cursor: "I") should not be available. It should just be a dropdown where the user can select the option.
2. I am getting data from URL and passing it as an object to "value" in multiselect example
value:getFieldValues()//在函数中,我返回我在初始化时设置为multiselect的值的对象。
示例:[Object {PLACE =“Bangalore”,TYPE =“city”},Object {PLACE =“Anderson”,TYPE =“city”}]是getFieldValues()返回的对象。
多选中的值设置为“班加罗尔”两次。请让我知道为什么会这样?
请在问题中找到w.r.t的示例
http://jsbin.com/asAdurO/1/edit
谢谢Bharath
答案 0 :(得分:0)
Enclose the MULTISELECT in a div/span and add this code in script :
$(#divID).on('keypress', function(e) {
e.preventDefault();
});