W3 Schools CSS - Card wont center

NorseMan

Member
I have tried different things to center the card below. But it doesn't. What am I doing wrong?
The other styles are working, but it won't center, no matter what. Maybe there is a simple solution for this, but as said, it doesn't work. I have tried inline CSS too. Is it a simple solution for this?

<div class=" w3-card w3-center w3-padding w3-twothird w3-round">
 
Inline styles are not the best way, so you can create a new class for that. Any css framework isn't perfect so custom css classes are allways needed
 
I've worked a lot with w3school's css framework so I know it well, but I'm still not very experienced with it. So things like that you mention are not so unknown, but I need to hear it to get a reminder since I am not so experienced that everything comes automatically. So thanks for mentioning it 😊👍

I have tried different css frameworks, but it is w3schools css that I think is the easiest to learn and is the most/best developed so far.
 
you can also check the bootstrap (it's very popular) or bulma. I worked with bootstrap many times in projects that I developed so if you will work on any project that was created by someone else then you will need to learn it. I found the bulma css framework when I tried to find good alternative
 
I will check them out, but i think i will stay where i am (or with what i got).
I have tried bootstrap before, but there is a reason i was choosing the w3schools css.
The two other ones i can give a try (at least look at it), but i think i will stay where i am, with the w3schools css framework.
 
I will check them out, but i think i will stay where i am (or with what i got).
I have tried bootstrap before, but there is a reason i was choosing the w3schools css.
The two other ones i can give a try (at least look at it), but i think i will stay where i am, with the w3schools css framework.
 
Back
Top