L
L
locus2015-01-16 15:37:36
Slider
locus, 2015-01-16 15:37:36

How to display a slider in bootstrap to the full width of the page?

I'm making up a page according to the template bootstrap-3.ru/examples/justified-nav
. I'm trying to insert a full-width slider right under the navigation. He, the dog, does not want to stretch. Written like this:

!DOCTYPE html>
<html lang="ru">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <meta name="description" content="">
    <meta name="author" content="">
    <title>Натяжные потолки в Санкт-Петербурге</title>
    <!-- Bootstrap core CSS -->
    <link href="css/bootstrap.min.css" rel="stylesheet">
  <link href="css/style.css" rel="stylesheet">
  <link href='http://fonts.googleapis.com/css?family=Exo+2:300&subset=latin,cyrillic' rel='stylesheet' type='text/css'>
    <!-- Custom styles for this template -->
    <link href="css/justified-nav.css" rel="stylesheet">
    <!-- Just for debugging purposes. Don't actually copy this line! -->
    <!--[if lt IE 9]><script src="../../assets/js/ie8-responsive-file-warning.js"></script><![endif]-->
    <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!--[if lt IE 9]>
      <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
      <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
  </head>
  <body>
<div class="container">

<div class="row">
<div class="col-md-4">
<div id="logo"><a title="" href="/"><img alt="" src="img/logo.png"></a></div>
</div>
<div class="col-md-4"></div>
<div class="col-md-4"><div class="telephone"><span class="tel">(812)<span>454-20-10</span></span></div>
<div class="clearfix"></div>
<div class="add">
<span>ул. Ленсовета д.70</span><br/>
<span>пр. Просвещения д.30 к.1</span><br/>	
<span>ул. Дыбенко д.24 к.1</span><br/>
</div>
</div>
<div>
  
<div class="masthead">
<ul class="nav nav-justified">
<li><a href="#"> О компании</a></li>
<li><a href="#">Натяжные потолки</a></li>
<li><a href="#">Акции и скидки</a></li>
<li><a href="#">Цены</a></li>
<li><a href="#">Услуги</a></li>
<li><a href="#">Гарантии</a></li>
<li><a href="#">Для дилеров</a></li>
<li><a href="#">Контакты</a></li>
</ul>
</div>

</div> <!-- /container -->


<div class="container-fluid">
<div class="row">
<div id="carousel-example-generic" class="carousel slide" data-ride="carousel">
  <!-- Индикаторы -->
  <ol class="carousel-indicators">
    <li data-target="#carousel-example-generic" data-slide-to="0" class="active"></li>
    <li data-target="#carousel-example-generic" data-slide-to="1"></li>
    <li data-target="#carousel-example-generic" data-slide-to="2"></li>
  </ol>
  <!-- Содержимое слайдера (Обёртка для слайдов)-->
  <div class="carousel-inner">
    <div class="item active">
      <img src="img/big-header.jpg" alt="...">
      <div class="carousel-caption">
        <p>первый слайд</p>
      </div>
    </div>
    ...
  </div>
  <!-- Контролы -->
  <a class="left carousel-control" href="#carousel-example-generic" data-slide="prev">
    <span class="glyphicon glyphicon-chevron-left"></span>
  </a>
  <a class="right carousel-control" href="#carousel-example-generic" data-slide="next">
    <span class="glyphicon glyphicon-chevron-right"></span>
  </a>
</div>
</div>
</div> <!-- /container -->

How to stretch the slider to the full width of the window? tell me please.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
Z
Zarema Khalilova, 2015-01-16
@Zmoki

You have a mess with closing =)
After

<div class="masthead">
<ul class="nav nav-justified">
<li><a href="#"> О компании</a></li>
<li><a href="#">Натяжные потолки</a></li>
<li><a href="#">Акции и скидки</a></li>
<li><a href="#">Цены</a></li>
<li><a href="#">Услуги</a></li>
<li><a href="#">Гарантии</a></li>
<li><a href="#">Для дилеров</a></li>
<li><a href="#">Контакты</a></li>
</ul>
</div>

</div>

add two more </div>, close the row and container divs.
PS use an IDE or an editor with code auto-formatting, it will be much more convenient.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question