EasyUI Forum
May 08, 2024, 10:28:52 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: SearchBox incorrect width  (Read 14447 times)
Kevin
Jr. Member
**
Posts: 52


View Profile Email
« on: October 04, 2012, 05:42:24 AM »

After upgrading to version 1.3.1 the SearchBox does not apply a width attribute to the INPUT tag. This only occurs when no menu is applied. Running the code below will demonstrate this. The first SearchBox displays correctly (with a menu), the second not (without a menu). This was tested in FF, Chrome and IE. All gave the same results.

Code:
<!DOCTYPE html>
<html>
<head>
   <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
   <title>SearchBox - jQuery EasyUI Demo</title>
   <link rel="stylesheet" type="text/css" href="http://www.jeasyui.com/easyui/themes/default/easyui.css">
   <link rel="stylesheet" type="text/css" href="http://www.jeasyui.com/easyui/themes/icon.css">
   <script type="text/javascript" src="http://www.jeasyui.com/easyui/jquery-1.8.0.min.js"></script>
   <script type="text/javascript" src="http://www.jeasyui.com/easyui/jquery.easyui.min.js"></script>
</head>
<body>
   <input class="easyui-searchbox" data-options="prompt:'Please Input Value',menu:'#mm',searcher:function(value,name){alert(value+':'+name)}" style="width:300px"></input>
   <div id="mm" style="width:120px">
      <div data-options="name:'all',iconCls:'icon-ok'">All News</div>
      <div data-options="name:'sports'">Sports News</div>
   </div>
   <input class="easyui-searchbox" data-options="prompt:'Please Input Value', searcher:function(value,name){alert(value+':'+name)}" style="width:400px"></input>
</body>
</html>
Logged
stworthy
Administrator
Hero Member
*****
Posts: 3581


View Profile Email
« Reply #1 on: October 04, 2012, 05:59:36 AM »

Change jQuery to 1.7.2 or lower and it will display correctly. The jQuery 1.8.x compatible issue has been fixed. Download it from http://www.jeasyui.com/easyui/plugins/jquery.searchbox.js.
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!