Home › Forums › CSS › Center the loading .gif in the middle of the screen? › Re: Center the loading .gif in the middle of the screen?
I know it’s marked as solved but small tip:
margin: 0 auto;
Will only center your image horizontally. What would I do is:
// Lets say your loading.gif is 100px by 100px
margin: -50px 0px 0px -50px;
This will center it horizontally and vertically. Margin should be twice less that your image size, so if your image is 100x50px, margin should be -50px 0px 0px -25px.