+ 1
Please help me to center the text in navigation menu
I need to center words "Czech Republic" (horizontal and vertical). And these words must be in two lines. Here is my code: https://code.sololearn.com/Ws3f7dvWAZCT/?ref=app Here is a picture of what I have to do: https://www.sololearn.com/post/1636292/?ref=app Thank you!
6 Answers
+ 1
Try
.word-czesh-rep {
display: block;
text-align: center;
}
+ 1
For vertically middle with display flex
try
ul {
align-items: center;
}
+ 1
CalviŐ˛ Thank you very much!!!
0
0
CalviŐ˛ Thank you! Now it is horizontal in the middle! And how to make it vertically in the middle?
0
For Vertical: comment out the display flex;
.menu {
text-align: center;
}
ul{
list-style: none;
/* display:flex */
justify-content: flex-start;
}