Reputation: 1
I'm trying to center align specific characters in a body of text for a website. I would like to only center things that have "[], *" and Roman numerals. Is there a way I can only center these without having to manually set a div tag for every single one?
Example, the "[E]" here would be centered on the page:
[E]
The house was red
Thanks! :)
Upvotes: 0
Views: 218
Reputation: 346
I believe it is not possible since both css and html doesn't have those "if" statements, where you can tell it to do something when a condition is met.
You may use the <center> tag in html or text-align:center for css instead.
Upvotes: 1