How to vertically center a text?
I am using a div tag i can center a text horizontal, but how can I center a vertically .. .. https://code.sololearn.com/W7nuyPxvzV8C/?ref=app
Or use the flexbox-layout on the div. display: flex; align-items: center; justify-content: center;
Just make line-height same as the div height e.g. line-height: 20vh; https://code.sololearn.com/WTU34IS6CycX/?ref=app
You can also use the grid layout, instead of flexbox, and just write two lines of code. display: grid; place-items: center; You won't need the text-align property anymore, since the place-items property centers the content both horizontally and vertically.
Use a span tag to format the text style (rather than the div style). In the style, use position:relative and specify distance from top (of parent element - the div) around 50%.
display: flex; align-items: center;
Please help me with HTML
What is the mistake here?
Unable to overload +
I have tried every way I could find but still I can't display my local images ..what am I doing wrong?
Pls rectify the errors.
Python list half printed