Ask coding questions

← Back to all posts
How do I center an image in the middle of the screen?
kenzielixir

I'm working on a project and can't remember how to center an image...

Answered by InvisibleOne [earned 5 cycles]
View Answer
Voters
kenzielixir
Comments
hotnewtop
InvisibleOne

In the css:

you can also try:

which will center everything on the page

kenzielixir

Oh wow my code was messed up...
Thanks for the help and corrections!

Coder100

position absolute? idk
anyways your html is super messed up, replace it to:

css