Hello, in this bootstrap four video, we're going to show you how you can invert the color of your card. Because if you have a look at the moment, just ignore the image, we're not going to be inverted any of that, because that's an image, we have a white background inside the card body, you might think it's just the default thing. And generally, it's still white. We have some text, which is black, and I believe is black as well or really, really dark gray. Either way, we've got dark text and a light background, but you might want it reversed. You might want a dark background and white text.
The obvious way to do that is apply CSS for the background. Apply CSS for this for CSS, CSS for this and any other items that become quite tedious to invert it. There are literally two things that you really need to do. Add a class to the entire called div container and the Classes card dash inverse, save it. And now if we go to our browser refresh, this text hasn't disappeared. It's still here.
It's just white now. And what we're going to do is just manually change the background color of the card. I'm using inline styling just so it's easier for this video. Generally, you'll want to use a CSS file. So I'm going to put back ground dash color and set it to black, something that's dark works well. Go back refresh.
And there you go. We have a black background, which we applied one line of CSS, and using the cord that inverse, these two pieces of text, have no change color. This is white, and that this is gray. And what's great about this is the title is something that needs to really stand out. So if it's a post on a blog, you want it to attract the user. So they is brighter than the main text, the main text is still more than readable.
It's not like you can't read it, it's just not as prominent as the total. That's all handled within bootstrap. So that's called inversions for you, in bootstrap, if you have any questions, feel free to post them on our education platform. So now learning Dakota, UK forward slash question dot php, there'll be a link in the description to that website. Plus, there's also thousands of videos for free on our education platform. So check them out, as well.
There'll be another link in the description to the source code from this video, and the source code from every other video in this series. Please rate, comment and subscribe and it doesn't really help us provide more content to you on a regular basis. And as usual, I'm Georgia and I hope you have a great day.