Html 从第二行删除行高度

Html 从第二行删除行高度,html,css,Html,Css,我给了一个标签60px的行高,但文的内容更多,它去了第二行,但即使第二行也取了60px的行高。如何从第二行删除行高度 在这里,要将文本垂直居中对齐到div,需要使用行高 a.pname { font-family:Verdana, Geneva, sans-serif; font-size:14px; color:#000; text-align:left; font-weight:normal; text-decoration:none; line-height:65px; float:l

我给了一个标签60px的行高,但文的内容更多,它去了第二行,但即使第二行也取了60px的行高。如何从第二行删除行高度

在这里,要将文本垂直居中对齐到div,需要使用行高

a.pname
{ font-family:Verdana, Geneva, sans-serif; font-size:14px; 
color:#000; text-align:left; font-weight:normal;
text-decoration:none; line-height:65px; 
float:left; background-color:#090; width:190px 
}
使用伪元素仅选择第一行。从样式中删除“线高度”特性并添加此属性

a.pname:first-line { line-height: 65px; }