Textfield with a dropdown list while writing some text

T

t.kiesche

Hello

I want to make a textfield (INPUT type=text) or something that looklike
this, to drop down a list with word.

Just like:

A user writes the letter 'a' and in the dropdown list come a list of
word starting with 'a'.

The user is writing 'b' after this, the dropdown list contains all
words starting
with 'ab'.

when the user pick a word with mouse or arrow key, the word is now
standing in the text field.

I is just like as the address bar in the webbrowser.

Can someone help me to make this for my webpage?

thanks
 
R

RobG

Hello

I want to make a textfield (INPUT type=text) or something that looklike
this, to drop down a list with word.

Just like:

A user writes the letter 'a' and in the dropdown list come a list of
word starting with 'a'.

The user is writing 'b' after this, the dropdown list contains all
words starting
with 'ab'.

There is an example here that sort of does what you are after, search
for 'auto-complete' or 'type ahead'.

<URL:http://www.mattkruse.com/javascript/autocomplete/>

I have seen examples where the select element is absolutely positioned
below the text input and appears when typing starts. It moves through
selections depending on typing, disappearing if no match if available or
when a selection is made. There are usability issues that are difficult
to overcome.

Usually it is far better if the user can actually see the option values
so they know what to type, hence the version above that allows users to
type-ahead if they want or use the select 'drop down' to select an option.

[...]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,577
Members
45,052
Latest member
LucyCarper

Latest Threads

Top