+ 11
What tag should I use to align a text to center
10 Answers
+ 5
Hej Surafel
Don't use a center tag. Iâd advice you to use the text-alignment attribute on your paragraphâs class.
.classname p {
text-align: center;
}
+ 11
Thanks for all of you
+ 5
Three ways!
<center> </center>
OR
<p align= âcenterâ> </p>
OR
In CSS
.text {
text-align: center;
}
+ 3
<center>...</center>
+ 3
<div Align="center">
<p>Hello</p>
</div>
+ 2
better still you can use CSS syntax to style your html document...over and above using the html tags.
+ 2
align=âcenterâ. this must be places in the tag for the text.
+ 2
Eyob Bezaneh please do not copy another userâs previous answer.
đ˛JTLZ đ˛ [#Never Give Up!] look at the previous comment.
+ 1
<center> </center>
OR
<p align= âcenterâ> </p>
OR
In CSS
.text {
text-align: center;
}
0
<center> </center> is a tag used to display data in center
ex :
<center>
This is center tag
</center>
align attribute is also available to display data in center
Note : since it is attribute it must be in any of the tags
ex
<h1 align=âcenterâ> This is center attribute </h1>
In css
text-align: center;
ex
<div>
THIS IS SAMPLE
</div>
div
{
text-align: âcenterâ;
}