N
N
Nemby2017-01-13 13:20:20
Bootstrap
Nemby, 2017-01-13 13:20:20

How to insert a 300x200px logo image into the navbar so that it doesn't go out of bounds?

Good afternoon.
Can you please tell me how to insert a 300x200px logo image into the navbar so that it does not go beyond the borders?

<nav class="navbar navbar-default">
  <div class="container-fluid">
    <div class="navbar-header">
      <a class="navbar-brand" href="#">
        <img alt="Brand" class="img-responsive" src="/logo.png">
      </a>
    </div>
  </div>
</nav>

10e2156d3642450199f89022bf57a212.png

Answer the question

In order to leave comments, you need to log in

2 answer(s)
N
Nemby, 2017-01-13
@Nemby

Found a solution:
instead of

<a class="navbar-brand" href="#">
<img alt="Brand" class="img-responsive" src="/logo.png">
</a>

you need to register
attach to the left side and everything works as it should and does not go out of bounds

P
Pavel, 2017-01-13
@PavelMonro

For example, add dimensions for the block:
<div class="navbar-header col-md-4">

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question