0
<script type="text/javascript">
$().ready(function() {
    $(".auto").autocomplete("omsaiautocomplete.php",{
       width: 260,
       matchContains: true,
       //mustMatch: true,
       //minChars: 0,
       //multiple: true,
       //highlight: false,
       //multipleSeparator: ",",
       selectFirst: false   
    }); 
});
</script>

<script type="text/javascript">
    $().ready(function() {
        $(".auto").autocomplete("omsaiautocomplete1.php",{
           width: 260,
           matchContains: true,
           //mustMatch: true,
           //minChars: 0,
           //multiple: true,
           //highlight: false,
           //multipleSeparator: ",",
          selectFirst: false
        });
    });
</script>

i have above code which is used for two textboxes having autocomplete applied to them.is it right? plz provide answer.

1
  • 1
    Format the code please. There's a handy guide to the right of the "Add/Edit Question" box, with a link to further instructions. Commented May 24, 2011 at 12:08

1 Answer 1

2

You are trying to setup both autocompletes on the same text boxes (ones with the class 'auto'). Give each textbox a unique class/ID and then setup the autocomplete using that instead.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.