Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    New Coder
    Join Date
    Jun 2002
    Posts
    64
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Auto Complete Like Text Box

    Has there been or is there any method or function already created that will based on the entry event cause a textbox to behave such as the auto complete feature in IE?

    e.g. Can you make a text box that behaves like a drop-down combo list box?

    Any/All suggestions are welcomed!

    Thanks!

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Location
    Beyond Lament
    Posts
    424
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quíet Storm Designs ~ Art is not what you see, but what you make others see.
    · the Storms· || ·Ultraviolent Winter· || ·Was Einstein Wrong?· || ·It´s About Time!·

  • #3
    New Coder
    Join Date
    Jun 2002
    Posts
    64
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Disabling Method

    QuietStorm, thanks for the link...

    I want to "enable" a similar feature but not the autocomplete in IE.

    The feature would provide a set of values to allow the end user to choose from or be able to type in their own value.

  • #4
    Senior Coder
    Join Date
    Jun 2002
    Posts
    1,404
    Thanks
    2
    Thanked 32 Times in 32 Posts
    You can pretty much re-engineer form controls into behaviors of your choosing; MSIE 'autocomplete', obviously, involves a pretty sophisticated level of data manipulation and would require a lot of work. If you're just looking for something to impress/spoil your users, here's a easy sample:


    <html>
    <head>
    <title>untitled</title>
    <style type="text/css">

    table {
    font: 200 14px "times new roman";
    color: orange;
    margin: 0px;
    padding: 0px;
    border:3px darkgreen double;
    background: black;
    }

    input {
    width: 100px;
    border: 1px darkred solid;
    background: ivory;
    }

    select {
    background: orange;
    }

    </style>
    </style>
    </head>
    <body>
    <form>
    <table><tr><td>My website is</td><td>
    <input name="t1" type="text"
    onfocus="choices.style.visibility='visible'"
    onkeypress="choices.style.visibility='hidden'"></td></tr><td></td><td>
    <select name="choices" style="visibility:hidden;"
    onchange="if(this.selectedIndex)t1.value=this[this.selectedIndex].value;
    this.selectedIndex=0;
    this.style.visibility='hidden'">
    <option selected="selected">choose</option>
    <option value="awful">Awful</option>
    <option value="bad">Bad</option>
    <option value="barely tolerable">Barely Tolerable</option>
    <option value="disturbing">Disturbing</option>
    <option value="steve">Steve</option>
    </select>
    </td></tr></table>
    </form>
    </body>
    </html>


  • #5
    New Coder
    Join Date
    Jun 2002
    Posts
    64
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Thanks!

    Thanks Adios that is really slick!!

    I added in "multiple" to the select tag and it behaves exactly as I wanted!!

    I appreciate you taking the time to code it out!

    Thanks for sharing all your knowledge!


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •