| 1 | <!doctype html> |
| 2 | <html lang="en"> |
| 3 | <head> |
| 4 | <meta charset="utf-8"> |
| 5 | <meta name="viewport" content="width=device-width, initial-scale=1"> |
| 6 | <title>jQuery UI Autocomplete - Default functionality</title> |
| 7 | <link rel="stylesheet" href="../../themes/base/all.css"> |
| 8 | <link rel="stylesheet" href="../demos.css"> |
| 9 | <script src="../../external/requirejs/require.js"></script> |
| 10 | <script src="../bootstrap.js"> |
| 11 | var availableTags = [ |
| 12 | "ActionScript", |
| 13 | "AppleScript", |
| 14 | "Asp", |
| 15 | "BASIC", |
| 16 | "C", |
| 17 | "C++", |
| 18 | "Clojure", |
| 19 | "COBOL", |
| 20 | "ColdFusion", |
| 21 | "Erlang", |
| 22 | "Fortran", |
| 23 | "Groovy", |
| 24 | "Haskell", |
| 25 | "Java", |
| 26 | "JavaScript", |
| 27 | "Lisp", |
| 28 | "Perl", |
| 29 | "PHP", |
| 30 | "Python", |
| 31 | "Ruby", |
| 32 | "Scala", |
| 33 | "Scheme" |
| 34 | ]; |
| 35 | $( "#tags" ).autocomplete({ |
| 36 | source: availableTags |
| 37 | }); |
| 38 | </script> |
| 39 | </head> |
| 40 | <body> |
| 41 | |
| 42 | <div class="ui-widget"> |
| 43 | <label for="tags">Tags: </label> |
| 44 | <input id="tags"> |
| 45 | </div> |
| 46 | |
| 47 | <div class="demo-description"> |
| 48 | <p>The Autocomplete widgets provides suggestions while you type into the field. Here the suggestions are tags for programming languages, give "ja" (for Java or JavaScript) a try.</p> |
| 49 | <p>The datasource is a simple JavaScript array, provided to the widget using the source-option.</p> |
| 50 | </div> |
| 51 | </body> |
| 52 | </html> |