[英]How can I create a modal dialog with a text and a listbox with javascript
Since I am new in javascript my question is how can I create a modal dialog using javascript. 由于我是javascript新手,因此我的问题是如何使用javascript创建模式对话框。 In this modal dialog I want to have 3 controls.
在此模式对话框中,我想要3个控件。 An editbox, a textbox and a listbox.
一个编辑框,一个文本框和一个列表框。 The user enters value in the edit box and if there are more than one result i want to display it in the listbox.
用户在编辑框中输入值,如果有多个结果,我想在列表框中显示它。 Then the user selects one from the listbox and pressing the OK button the dialog returns the selected value.
然后,用户从列表框中选择一个,然后按“确定”按钮,对话框将返回所选值。
I 've been trying to find a sample code to do this with no luck. 我一直在寻找一个示例代码来做到这一点。 Can anyone help?
有人可以帮忙吗?
I would recommend a javascript library like dhtmlx (or jQuery, I haven't tried that). 我会推荐像dhtmlx这样的javascript库(或jQuery,我没有尝试过)。
http://dhtmlx.com/docs/products/dhtmlxWindows/index.shtml http://dhtmlx.com/docs/products/dhtmlxWindows/index.shtml
With dhtmls you can define custom modal windows by javascript! 使用dhtml,您可以通过javascript定义自定义模式窗口!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.