Omar2057
Omar2057

Reputation: 5

grid dont work with bootstrap

supposed to divide a row of two, but showing two rows, this is the code... im using the bootstrap v3.1.1 and the tutorial that i see use bootstrap V3 be diferent?

<!DOCTYPE html>
<html>
<head>
    <title>probando</title>
<link rel="stylesheet" type="text/css" href="bootstrap/css/bootstrap.css">

    <p>probando nuevas cosas</p>
</head>

<body>

    <div class="container">
        <div class="row">
            <div class="span6">
            <h1>Debe estar mas resaltado</h1>

            <p>proabando con mas palbras pra ver que pasa</p>
            </div>

            <div class="span6">
            <h1>Debe estar mas resaltado</h1>

            <p>proabando con mas palbras pra ver que pasa</p>
            </div>

        </div>

    </div>

</body>
</html>

Upvotes: 0

Views: 63

Answers (3)

Amarjit Datta
Amarjit Datta

Reputation: 56

Seems like your trying v2 in v3 to me. span6 is outdated.

Should be something like this

<div class="row">
  <div class="row">
    <div class="col-md-6">
      <h1>Debe estar mas resaltado</h1>
      <p>proabando con mas palbras pra ver que pasa</p>
    </div>
    <div class="col-md-6">
      <h1>Debe estar mas resaltado</h1>
      <p>proabando con mas palbras pra ver que pasa</p>
    </div>
  </div>
</div>

Finaly...one small thing (I guess you already added), I haven't see bootstrap js and viewport code in your code here. So just in case you forgot to add, you'll have to add something like this in your header...

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <!-- Bootstrap CSS -->
    <link href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css" rel="stylesheet" />

Upvotes: 1

cvrebert
cvrebert

Reputation: 9289

span6 indicates that your tutorial is for the now-pretty-outdated Bootstrap v2, which isn't compatible with v3. Find yourself a newer tutorial. Or, ya know, just read the official docs; they're very thorough and give tons of examples. :-)

Upvotes: 1

rubo123
rubo123

Reputation: 186

Your classes should be "col-xs-6" see the bootstrap documentation - http://getbootstrap.com/css/#grid

Upvotes: 2

Related Questions