Guest User

Untitled

a guest
Apr 20th, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.72 KB | None | 0 0
  1. <select style="width: 500px;">
  2. <option value="1">
  3. This is a very long option, but it's cool, cause the select is also very long
  4. </option>
  5. </select>
  6.  
  7. $(function() {
  8.  
  9. $(".SecuritySelect")
  10.  
  11. .mouseover(function(){
  12. $(this)
  13. .data("origWidth", $(this).css("width"))
  14. .css("width", "auto");
  15. })
  16.  
  17. .mouseout(function(){
  18. $(this).css("width", $(this).data("origWidth"));
  19. });
  20.  
  21. });
  22.  
  23. position: absolute
  24.  
  25. width: 500
  26.  
  27. $('select#CourtId')
  28. .focus(function() { $('select#CourtId').css('position', 'relative').css('margin-right', '-300px').css('min-width', $('select#CourtId').css('width')).css('width', 'auto'); })
  29. .blur(function() { $('select#CourtId').removeAttr('style'); });
Add Comment
Please, Sign In to add comment