Мне нужно спозиционировать текст внутри div по вертикале, чтобы текст был по середине. Нормально ли для этого использовать line-height со значением высоты контейнера?
You can post now and register later.
If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.
Question
egiko
День добрый!
Мне нужно спозиционировать текст внутри div по вертикале, чтобы текст был по середине. Нормально ли для этого использовать line-height со значением высоты контейнера?
Пример:
height div : 20px
line-height div : 20px
Link to comment
Share on other sites
3 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.