1
As I put an image in the right corner of a menu bar with bootstrap. Below the code of my Layout(Master)
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title></title>
@Styles.Render("~/bundles/css")
@Scripts.Render("~/bundles/modernizr")
@Scripts.Render("~/Scripts/Util.js")
</head>
<body>
<div class="navbar navbar-inverse navbar-fixed-top">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
@*@Html.ActionLink("Pedidos", "Index", "Home", null, new { @class = "navbar-brand" })*@
</div>
<div class="navbar-collapse collapse">
<ul class="nav navbar-nav">
</ul>
</div>
</div>
</div>
<div class="container body-content">
@RenderBody()
<hr />
<footer>
<p>© @DateTime.Now.Year</p>
</footer>
</div>
@Scripts.Render("~/bundles/jquery")
@Scripts.Render("~/bundles/bootstrap")
@RenderSection("scripts", required: false)
</body>
</html>
I did that, but the image was left and not right.
..........
<div class="container">
<a class="brand"><img src="~/Images/ache.jpg" /></a>
<div class="navbar-header">
.............
Both answers worked. I’ll mark one, but I consider both correct.
– pnet