textarea label vertical-align: middle

前端 未结 5 1515
甜味超标
甜味超标 2021-02-14 02:45

I\'m trying to align the label for this text area in the middle of the text box, but it just isn\'t working. The output looks something like this:

          xxxx         


        
5条回答
  •  抹茶落季
    2021-02-14 03:35

    you can do it like this:

    label { display:inline-block; vertical-align:central; }
    
    textarea { display:inline-block; vertical-align:middle; }
    

提交回复
热议问题