2011-05-20 47 views
2

我得到了這個小問題,但我覺得很難解釋,請耐心等待。Textarea佈局問題

我在一個textarea的前面有一個標籤,它看起來像這樣: screenshot

實際上我想這樣的:

enter image description here

這是我的代碼:

<form method="post" action="" name="myform" id="form"> 
<label>Naam :</label> 
<input type="text" id="naam" name="naam" size="40" /> 
<br /> 
<label>Email :</label> 
<input type="text" id="email" name="email" size="40" /> 
<br /> 
<label>Bericht :</label> 
<textarea cols="30" rows="7" id="bericht" name="bericht"></textarea> 
<br /> 
<label>&nbsp;</label> 
<input class="submit" id="btnZend" name="submit" type="submit" value="Verzend bericht" /> 

CSS中的標籤是:width:150px; text-align:right;

在此先感謝

回答

5
textarea { vertical-align: top; } 
+0

啊哈!謝謝 – 2011-05-20 16:10:04