如何以jQuery UI样式创建标准组合框(选择)? [英] How to create standard combobox (select) in jquery ui style?

查看:78
本文介绍了如何以jQuery UI样式创建标准组合框(选择)?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

组合框启用了自动填充功能.如何创建具有相同样式但没有自动完成功能(只有几个固定值)的组合框?

There is combobox with autocomplete enabled. How to create combobox in the same style but without autocomplete (with just a few fixed values)?

推荐答案

如果我从根本上理解您,则不希望允许用户输入,并且应通过单击按钮或文本框来更改值.为此,您可以使用"readonly"属性,如下所示:

If I understood you corectly you want not to allow user input and values shall be changed by click on button or textbox. For this purpose you can use "readonly" attribute like this:

input.attr("readonly", true);

当然,您可以实现您的窗口小部件并通过插件选项进行设置.

Of course you my implement your widget and set it up by plugin options.

这篇关于如何以jQuery UI样式创建标准组合框(选择)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆