asp.net - Align controls properly -


i want adjust appearance on same controls on website working on, seems not going good. want use css align controls. want have checkbox , label aligned left , little bit room, textbox coming. want textboxes aligned same vertically. how can css without using tables.

enter image description here

thanks in advance help, laziale

css

div{margin-bottom:2px;} input[type="checkbox"]{display:block; float:left; margin-right:2px;} label{display:block; float:left; width:150px;} 

html

<div><input type="checkbox" /><label>address</label><input type="text" /></div> <div><input type="checkbox" /><label>state</label><input type="text" /></div> <div><input type="checkbox" /><label>city</label><input type="text" /></div> <div><input type="checkbox" /><label>zip</label><input type="text" /></div> <div><input type="checkbox" /><label>contact person</label><input type="text" /></div> <div><input type="checkbox" /><label>contact person</label><input type="text" /></div> 

Comments

Popular posts from this blog

java - SNMP4J General Variable Binding Error -

windows - Python Service Installation - "Could not find PythonClass entry" -

Determine if a XmlNode is empty or null in C#? -