html - Trouble aligning button with input -


i've tried align button submit , search input doesn't work , don't understand why. have styling code:

input[type=search]      border: none     cursor: text     padding: 0     border: 1px solid #cfcfcf .search-main input, .search-main button     height: 30px     display: inline-block  .search-main button      background: #55e0a8     border: none     width: 18%     margin-left: -7px     display:inline-block  .search-main input     width: 80% 

and html:

<form method="get" class="search-main">     <input name="q" type="search">     <button type="submit"></button> </form> 

and here's get:

enter image description here here's online version

so, pretty silly question, since i've been trying more 40+ minutes, thought try post here. i've been playing firebug, padding, margins, , don't problem comes from.

you can try -

.search-main > button { float: right; } 

enter image description here


Comments

Popular posts from this blog

Change php variable from jquery value using ajax (same page) -

Pull out data related to my apps from Android Play Store and iOS App Store -

How can I fetch data from a web server in an android application? -