Centering content with bootstrap 3 - html

I am creating a small landing page at http://www.saleshuddlegames.com
on the desktop everything is fine but when I start using tablets and smartphones, everything starts going out of alignment. I can't seem to make anything centered.
Specifically look at my .footer
<footer>
<div class="row">
<div class="col-md-4 col-sm-10 col-sm-offset-2 col-xs-12 centered">
<ul class="social navbar-nav">
<li class="social-item"><i class="fa fa-facebook fa-3x"></i></li>
<li class="social-item"><i class="fa fa-instagram fa-3x"></i></li>
<li class="social-item"><i class="fa fa-youtube fa-3x"></i></li>
<li class="social-item"><i class="fa fa-twitter fa-3x"></i></li>
</ul>
</div>
</div>
<div class="row">
<div class="copyright col-md-6 col-md-offset-4 col-sm-10 col-sm-offset-2 col-xs-12">
<p>© 2013. The Training Game is property of Sales Huddle Group, Inc.</p>
</div>
</div>
</footer>
I used a centering snippet from a previous post:
.centered {
float:none;
margin: 0 auto;
}
Any Ideas??

Have you tried using the text-center class from bootstrap?
I've juggled the selection of columns for the social icons, and removed them all for the copyright text.. now this looks good here at all browser sizes:
<footer>
<div class="row">
<div class="col-md-4 col-md-offset-4 col-sm-4 col-sm-offset-4 col-xs-12 text-center">
<ul class="social navbar-nav">
<li class="social-item"><i class="fa fa-facebook fa-3x"></i></li>
<li class="social-item"><i class="fa fa-instagram fa-3x"></i></li>
<li class="social-item"><i class="fa fa-youtube fa-3x"></i></li>
<li class="social-item"><i class="fa fa-twitter fa-3x"></i></li>
</ul>
</div>
</div>
<div class="row">
<div class="copyright text-center">
<p>© 2013. The Training Game is property of Sales Huddle Group, Inc.</p>
</div>
</div>
</footer>

Related

Bootstrap : text on two lines instead of one

Good morning,
I use Bootstrap 4.5 and try to make a nice footer for my university site.
I use this :
<div class="container-fluid d-flex justify-content-center">
In order to have my footer centered and not the blocks being far away from each other.
But, on bigger screen (i emulated it with Firefox), the text is on two lines, because of the centered option and i would like to be on one line because it had space :
Here is the full code if it can be helpful :
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap#4.5.3/dist/css/bootstrap.min.css" integrity="sha384-TX8t27EcRE3e/ihU7zmQxVncDAy5uIKz4rEkgIXeMed4M0jlfIDPvg6uqKI2xXr2" crossorigin="anonymous">
<div class="container-fluid d-flex justify-content-center">
<div class="row">
<div class="col-lg-4 col-md-6 col-12 pb-5">
<h4 class="text-center">some text</h4>
<div class="d-flex justify-content-between align-items-center">
<a href="#" data-toggle="collapse" data-target="#footer_ups" aria-expanded="false" aria-controls="footer_ups">
<span><i class="fa fa-chevron-right pr-2"></i>some text some text sometext sometextsome text</span>
</a>
<span class="badge badge-primary badge-pill">7 <i class="fa fa-caret-down"></i></span>
</div>
<div id="footer_ups" class="collapse pl-3" aria-labelledby="some text">
<ul class="list-unstyled">
<li><i class="fa fa-angle-right pr-2"></i> some text</li>
<li><i class="fa fa-angle-right pr-2"></i> some text</li>
<li><i class="fa fa-angle-right pr-2"></i> some text</li>
</ul>
</div>
<div class="d-flex justify-content-between align-items-center">
<a href="#" data-toggle="collapse" data-target="#footer_ipp" aria-expanded="false" aria-controls="footer_ipp">
<span><i class="fa fa-chevron-right pr-2"></i>some text sometextsome text</span>
</a>
<span class="badge badge-primary badge-pill">4 <i class="footer_ipp_glyph fa fa-caret-down"></i></span>
</div>
<div id="footer_ipp" class="collapse pl-3" aria-labelledby="some text">
<ul class="list-unstyled">
<li><i class="fa fa-angle-right pr-2"></i> some text</li>
<li><i class="fa fa-angle-right pr-2"></i> some text</li>
<li><i class="fa fa-angle-right pr-2"></i> some text</li>
</ul>
</div>
<br />
<i class="fa fa-chevron-right pr-2"></i>some textsome textsome textsome texttextsome textsome text
</div>
<div class="col-lg-4 col-md-6 col-12 pb-4">
<h4 class="text-center">Aide et Informations légales</h4>
<ul class="list-unstyled">
<li><i class="fa fa-angle-right pr-2"></i> some text</li>
<li><i class="fa fa-angle-right pr-2"></i> some text</li>
<li><i class="fa fa-angle-right pr-2"></i> some text</li>
<li><i class="fa fa-angle-right pr-2"></i> some text</li>
</ul>
</div>
<div class="col-lg-4 col-md-12 text-center">
<h4 class="text-center">Suivez-nous</h4>
<i class="fa fa-facebook-square fa-3x mr-3"></i>
<i class="fa fa-twitter-square fa-3x mr-3"></i>
<i class="fa fa-linkedin-square fa-3x mr-3"></i>
<i class="fa fa-instagram fa-3x"></i>
</div>
</div>
</div>
Is this possible ?
Thank you !!
It is not possible because you used bootstrap pre-define class col- to adjust width.
If you want to convert two lines text into one class, your text will cut
It is possible only to not to use Bootstrap class, you use custom width to all columns

how do I design this footer with bootstrap and responsible?

I'm trying to get this design out, but it just didn't work out. Where do I make mistakes? how can I do that? Can you please help me.
I couldn't write much as CSS. I haven't even gotten the footer part right in the Middle yet.
this is my codes:
<link href="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-Vkoo8x4CGsO3+Hhxv8T/Q5PaXtkKtu6ug5TOeNV6gBiFeWPGFN9MuhOf23Q9Ifjh" crossorigin="anonymous">
<footer>
<div class="container">
<div class="row no-gutters">
<div class="col-lg-2 footer-left ml-auto">
<p class="more-info-title">more info</p>
<ul class="footer-left-info ">
<li>about us</li>
<li>delivery info</li>
<li>FAQs</li>
<li>terms and conditions</li>
<li>privacy policy</li>
<li>rydale jobs</li>
<li>sitemap</li>
</ul>
</div>
<div class="col-lg-2 footer-center mx-auto">
dave smith
</div>
<div class="col-lg-2 footer-right mx-auto">
<p class="find-us-title">find us</p>
<ul class="footer-right-info">
<li>
<a href="#">
<i class="fas fa-map-marker-alt"></i> rydale stockists
</a>
</li>
<li>
<a href="#">
<i class="fas fa-phone-alt"></i> shows & events
</a>
</li>
<li>
<a href="#">
<i class="far fa-envelope"></i> 01377 337160
</a>
</li>
<li>
<a href="#">
<i class="fas fa-map-marker-alt"></i> contact us
</a>
</li>
</ul>
</div>
</div>
</div>
</footer>
Use the order-N to reorganize the columsn on smartphone, for example
<footer>
<div class="container">
<div class="row no-gutters">
<div class="col-6 col-lg-3 order-2 order-lg-1 text-center">
<p><br><br>LEFT<br><br></p>
</div>
<div class="col-12 col-lg-6 order-1 order-lg-1 text-center">
<p><br><br>MIDDLE<br><br></p>
</div>
<div class="col-6 col-lg-3 order-2 order-lg-1 text-center">
<p><br><br>RIGHT<br><br></p>
</div>
</div>
</div>
</footer>

Styling a 5-column bootstrap footer

Sorry if it's a stupid question, I'm only starting to learn HTML, CSS and bootstrap. I've been trying to get a five-column footer on bootstrap.
So far I have achieved the five columns, but after hours of trying different things I have given up. I can't seem to figure out how to align the items in these columns.
You can see the full site here:
https://stevenarroyave.github.io/UPTAKE/
and the repo here:
https://github.com/stevenarroyave/UPTAKE
this is what I want it to look like:
https://drive.google.com/file/d/1bp2ZitBU4VGjPLhevdDZPBG5BeyEAO5X/view?usp=sharing
<footer>
<div class="col-sm-12 text-left">
<div class="row">
<div class="col-sm-7 five-three">
<div class="row">
<div class="col-sm-4">
<img id="logo" class="logo" src="img/FooterLogo.png"></img>
</div>
<div class="col-sm-4 text-left">
<h5 class="text mb-4">UPTAKE</h5>
<ul class="list-inline mb-0">
<li class="list-inline-item">
<h5>About us</h5>
<li class="list-inline-item">
<h5>Contact Us</h5>
</li>
<li class="list-inline-item">
<h5>Blog</h5>
</li>
</ul>
</div>
<div class="col-sm-4 text-left">
<h5 class="text mb-4">HELP</h5>
<ul class="list-inline mb-0">
<li class="list-inline-item">
<h5>FAQ</h5>
<li class="list-inline-item">
<h5>Tips and suggestions</h5>
</li>
<li class="list-inline-item">
<h5>Customer service</h5>
</li>
</ul>
</div><!-- end inner row -->
</div>
</div>
<div class="col-sm-5 five-two">
<div class="row">
<div class="col-sm-6 text-left">
<h5 class="text mb-4">LEGAL</h5>
<ul class="list-inline mb-0">
<li class="list-inline-item">
<h5>Privacy Notice</h5>
<li class="list-inline-item">
<h5>Terms of use</h5>
</li>
<li class="list-inline-item">
<h5>How to use Uptake</h5>
</li>
</ul>
</div>
<div class="col-sm-6 text-left">
<h5 class="text mb-4">LANGUAGE</h5>
<ul class="list-inline mb-0">
<li class="list-inline-item">
<input type="text" placeholder="English">
</li>
</ul>
</div>
</div><!-- end inner row -->
</div>
</div><!-- end outer row -->
<div class="row">
<div class="col-12 text-right">
<hr>
<h5>Follow us!</h5>
<i class="fab fa-facebook-f"></i>
<i class="fab fa-twitter"></i>
<i class="fab fa-google-plus-g"></i>
<i class="fab fa-youtube"></i>
<i class="fab fa-instagram"></i>
</div>
</div>
</div>
</footer>
As of now, I achieved the 5 columns, but as you can see, they all start at different heights, I'd like them to start at the same height, and stop the logo on the first column from resizing when resizing the window.
I also don't know how to get the pink icons on the bottom to show on the same line next to "Follow us!"
Thanks in advance for any help.
I am found some bug and fixed here screenshot change using the red mark arrow.
And your output is:
You need to defined align item to baseline. Try it specifically for footer row.
.row { align-items: baseline;}

How to give styling for active tab of nav-tab

This is my HTML Code. I want css styling for active nav-tab.Now i want when my page loads Location tab should have blue background how can i get that
<div class="row">
<div class="col-sm-12 col-xs-12 col-lg-12 col-md-12 welcome">
<ul class="nav navbar-nav navbar-nav-primary">
<li class="active">
<a href="#one" data-toggle="tab">
<i class="fa fa-map-marker" aria-hidden="true"></i>
<span class="li-text">Location</span>
</a>
</li>
<li>
<a href="#two" data-toggle="tab">
<i class="fa fa-heartbeat" aria-hidden="true"></i> <span class="li-text">Heartbeats</span>
</a>
</li>
<li>
<a href="#three" data-toggle="tab">
<i class="fa fa-power-off" aria-hidden="true"></i>
<span class="li-text">Reboots</span>
</a>
</li>
<li>
<a href="#four" data-toggle="tab">
<i class="fa fa-compress" aria-hidden="true"></i>
<span class="li-text">Reconnects</span>
</a>
</li>
<li>
<a href="#five" data-toggle="tab">
<i class="fa fa-battery-full" aria-hidden="true"></i>
<span class="li-text">Charge</span>
</a>
</li>
</ul>
</div>
Location tab is the active tab
<div id="one" class="tab-pane active">
<div class="row">
<div class="col-sm-offset-10 col-md-offset-10 col-xs-offset-10 col-lg-offset-10 col-sm-2 col-md-2 col-xs-2 col-lg-2 searchDiv">
<div class="row">
<div class="col-sm-1 col-xs-1 col-lg-1 col-md-1">
<i class="fa fa-search fa-2x" aria-hidden="true"></i>
</div>
<div class="col-sm-1 col-md-1 col-lg-1 col-xs-1">
<i class="fa fa-ellipsis-v fa-2x" aria-hidden="true"></i>
</div>
</div>
</div>
</div>
<div class="tab-pane active" id="1a">
<div ui-grid="gridOptions" class="grid-table" ui-grid-auto-resize ui-grid-cellNav ui-grid-edit ui-grid-resize-columns ui-grid-pinning ng-style="getTableHeight()"></div>
</div>
</div>
Now i want when my page loads Location tab should have blue background how can i get that.
Try this
CSS
.nav li.active a,
.nav li a:hover,
.nav li.active a:focus,
.nav li.active a:hover{
background-color:red;
}
Link for reference
hope this helps..
You can use it like this
.tab-pane.active {
background : blue; // or your desired color code.
}

CSS div positioning issue for cross platform web browsers

I have a web page ioterm which I tried to make it responsive. I tested on several web browsers FF, IE11 and Chrome 44. The problem is the div seems lower when it is displayed with Chrome. You can check it when you enter my sample page and navigate to products page. (WASPMOTE) When images slide, you will notice the WASPMOTE div positions lower than the others. It seems OK with FF and IE11. How can I fix this for Chrome?
Incase you can't access my page here is the images.imgur
Thanks in advance.
EdiT
Here is the problemmatic div.
<div class="row item active" id="one">
<div>
<div class="row ">
<div class="col-md-4" id="img1">
<img class="img-center" src="images/waspmote_pro_t.png" alt="waspmote">
</div>
<div class="col-md-4" id="img2">
<img class="img-center" src="images/waspmote_exp_radio_board_2-375_t.png" alt="waspmote">
</div>
<div class="col-md-4" id="img3">
<img class="img-center" src="images/u13_gw_t.png" alt="waspmote">
</div>
</div>
</div>
<div class="caption row ">
<div class="col-md-12">
<h3 class="productHeight">Waspmote</h3>
</div>
<div class="row" id="desc">
<div class="col-md-4" id="exp1">
<ul style="list-style-type: none;" class="productSize">
<li lang="tr">
<i class="fa fa-share-alt"></i> Tüm sensörlere bağlanabilir
</li>
<li lang="tr">
<i class="fa fa-rss"></i> Tüm wi-fi teknolojilerini destekler
</li>
<li lang="tr">
<i class="fa fa-cloud"></i> Bulut teknolojilerine uyumlu
</li>
</ul>
</div>
<div class="col-md-4" id="exp2">
<ul style="list-style-type: none;" class="waspmote">
<li lang="tr">
<i class="fa fa-check-circle"></i> Ultra düşük güç (0.7uA)
</li>
<li lang="tr">
<i class="fa fa-check-circle"></i> 100+ Sensör uyumluluğu
</li>
<li lang="tr">
<i class="fa fa-check-circle"></i> Kablosuz uzaktan programlama
</li>
<li lang="tr">
<i class="fa fa-check-circle"></i> Şifreleme Kütüphaneleri (AES, RSA)
</li>
<li lang="tr">
<i class="fa fa-check-circle"></i> Encapsulated line available
</li>
</ul>
</div>
<div class="col-md-4" id="exp3">
<ul style="list-style-type: none;" class="waspmote">
<li lang="tr">
<i class="fa fa-check-circle"></i> Desteklediği Protokoller: RS-232,RS-485,Modbus,CAN Bus, 4-20mA
</li>
<li lang="tr">
<i class="fa fa-check-circle"></i> 3G/GPRS/LoRaWAN/LoRa/Sigfox/868/900MHz,ZigBee/802.15.4/WiFi/RFID/ NFC/ Bluetooth 4.0
</li>
</ul>
</div>
</div>
</div>