Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis+ 11
What tag should I use to align a text to center
10 Respostas
+ 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ā;
}