Tweaking Bootstrap.

Really? The Bootstrap model isn’t funky enough for you? You want to add some clever tricks?

OK, we all know that making changes inline by using the “style=” attribute isn’t the best (or right) way to go about giving your jumbotron a blue background, but how to make it blue without all the grief of digging through the bootstrap.css file, and then updating the minified file afterwards?

Well this is the simplest way I know, just override the settings in bootstrap.css by using your own .css file, so if you want a blue background on your jumbotron simply make the modified declaration in a fresh file (mycss.css) like this;

.jumbotron {
    background: #337ab7; /* ComDotty logo blue */

All you have to do then is make sure you include your custom .css file after bootstrap.min.css and Roberts your mothers brother… Give it a moment, you’ll get there 😉

There is a secondary advantage to dealing with custom css using your own file. Everything you’re doing is in one place and once you’re finished there are any number of online and downloadable utilities you can use to minify the file if it gets that big!

So, my first, genuine, useful tip on the blog… Enjoy it for what its worth!

“I’ll be back” – T-101


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s