+ 2
I want to know how to centralise a text inside a box
To have a text appearing at the middle of a box.
7 Answers
+ 2
Finally my question is solved. Thank you KINGDX . God bless you.
+ 1
Use css
text-align: center;
+ 1
Sent the explanation of my question here already... check my message upward...
+ 1
Ok so if I got it right, you want to center a text inside a container vertically and horizontally.
Then the easiest way to achieve that is using flexbox.
I made a code demonstrating that for you. Check the CSS section at the bottom (the three last rules inside .centerxy).
https://code.sololearn.com/WcT1rfKThZKW/?ref=app
0
Thanks for your response, but I have tried that, I didn't get the desirable result. This is the desirable result I wanted, please check this screenshot.
0
Sorry I can't send screenshot. But I want the text to be at the middle of a box, there should be equal space up and down.