Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Implement multi column combo box using HTML + JavaScript

I am looking a multi columns combo box by using HTML + JavaScript only. Is there any example or library available? As I came across some solution, they are in ASP.NET, but not pure HTML + JavaScript.

Here is an example but it is implemented using Java Swing.

alt text

like image 347
Cheok Yan Cheng Avatar asked Nov 19 '10 01:11

Cheok Yan Cheng


3 Answers

If jQuery is an option, here's a plugin that looks like it can deliver this:

Jquery Multi Column Selectbox

like image 165
Surreal Dreams Avatar answered Nov 02 '22 09:11

Surreal Dreams


Flexbox is probably the best one I have ever used with jQuery, with paging and JSON support :

http://flexbox.codeplex.com/

It's a real combo box, as it displays the results by typing. It can be easily restyled through the CSS.

Eg. to modify the rows :

.ffb .content .row {
    border-bottom: 1px solid #828790;
    clear: both;
    color: #000000;
    height: 20px;
}

border-bottom may be removed to get rid of lines between rows.

like image 3
SuperDuck Avatar answered Nov 02 '22 11:11

SuperDuck


http://dev.sencha.com/deploy/dev/examples/form/combos.html Shows ExtJS's combo box. Their combo box can be customized with template to be used for rendering each entry. All you'd need to do is to specify a template that contains a few spans with a set width.

If you're willing to use ExtJS (not free), write it in here, and I'll show you an example

like image 2
Juan Mendes Avatar answered Nov 02 '22 09:11

Juan Mendes