Centering an image?

I have been trying to center my image in CSS and I don’t understand what’s going on. I can center it by fixing the position but it wont pass it on the tribute page. I’ve been stuck for days I can’t find the course on how to do it either! If anyone has advise on how they did it please share!

Hello and welcome.
Try using margin like this:

.test {
    margin: 0 auto;
}

This will center it horizontally.

Edit: I used .test as the class name of the image. Add a class to it and try use class name selector.

Heya you can also try:

img {
    vertical-align: middle;
    border-style: none;
}

This is what I use on my blog posts to center my images. You can see an example on the how much does it cost to wrap a car article. You can see each image sits nicely in the middle. Let me know if you can’t get it to work or if you meant centered from top to bottom of the screen. :+1: GL!