So, I'm moving from Wix to Neocities. And I can't really just take the pages from Wix and paste them into Neocities, so I need to remake a few things by hand now. I already asked google about this and got this as an answer: How do I position one image on top of another in HTML? Which, for only TWO images works, sort of fine, aside from the fact that it literally just breaks if I add align="center" to the div. It also just... doesn't really allow me to put more than the first two on top?
Here's the full code in the page:
<title>Work in progress...</title>
<link rel="icon" type="image/x-icon" href="/pages/images/favicons/main.png">
<link rel="stylesheet" type="text/css" href="/style.css">
<!-- CSS and div to make the site logo look the same as the Wix version, modified from https://stackoverflow.com/questions/48474/how-do-i-position-one-image-on-top-of-another-in-html
I might just put this into the main style.css, not sure.-->
<style>
.logo {
position: relative;
top: 0;
left: 0;
}
.image1 {
position: relative;
top: 0;
left: 0;
}
.image2 {
position: relative;
top: 0;
left: 0;
}
.image3 {
position: absolute;
top: 0px;
left: 0px;
}
</style>
<div class="logo">
<img class="image1" src="/pages/images/general/logo/1.gif" />
<img class="image2" src="/pages/images/general/logo/2.gif" />
<img class="image3" src="/pages/images/general/logo/3.gif" />
</div>
Since this stupid dumb site needs me to have 10 rep to even post images, you'll just have to take these links instead. At least I don't have to break the links like on GBATemp back when I was new there. I get that it's to prevent spam, but isn't there a better way?
Expected result: https://i.stack.imgur.com/suFVh.png
Actual result: https://i.stack.imgur.com/suXC7.png (screenshot left slightly uncropped to show that it's starting at the top-left of the page, not the absolute-regardless-of-window-size center like I want. plus the 3rd image (filename 3.gif) is completely outside of the div!)
I feel like a valve developer working on TF2. This shit doesn't work!! Why? Has I ever? In all seriousness, I'm still new to CSS and just want to know what the hell is wrong because doing it the HTML way would be WAY WAY easier for me than the "just put them all into one gif" way.
What I want in the end is for the div to just control the position of all 3 images inside of it, so that I can just put align="center" into the div's opening tag and have it just work.
Oh, and I'll put a live preview of the site at https://catboybeebop.neocities.org/pages/main_new.html, so you guys can see this all in action to better help me through this.