Autocomplete height and Button height

Autocomplete height and Button height

What am I doing wrong?



  1. <!doctype html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>demo</title>
  6. <link rel="stylesheet" href="http://code.jquery.com/ui/1.10.4/themes/ui-lightness/jquery-ui.css">
  7. <script src="http://code.jquery.com/jquery-1.10.2.js"></script>
  8. <script src="http://code.jquery.com/ui/1.10.4/jquery-ui.js"></script>
  9. <style type="text/css">
  10. #tags1 {
  11. height: 36px;
  12. }
  13. #but1 {
  14. height: 36px;
  15. }

  16. #tags2 {
  17. height: 30px;
  18. }
  19. #but2 {
  20. height: 36px;
  21. }
  22. </style>
  23. <script type="text/javascript">
  24. $(function() {
  25. var availableTags = ['Demo'];
  26. $('#tags1').autocomplete({
  27. source: availableTags
  28. });
  29. $("#but1").button();

  30. $('#tags2').autocomplete({
  31. source: availableTags
  32. });
  33. $("#but2").button();

  34. $('#tags3').height("36px").autocomplete({
  35. source: availableTags
  36. });
  37. $("#but3").height("36px").button();
  38. });
  39. </script>
  40. </head>
  41. <body>
  42. <input id="tags1" />
  43. <input type="submit" id="but1" value="Go" />
  44. <br /><br />
  45. <input id="tags2" />
  46. <input type="submit" id="but2" value="Go" />
  47. <br /><br />
  48. <input id="tags3" />
  49. <input type="submit" id="but3" value="Go" />
  50. </body>
  51. </html>