I have this code in _Layout.cshtml
<p class="site-title">@Html.ActionLink("your logo here", "Index", "Home")</p>
instead of "your logo here" I want to add the logo image.
For that you have to make some changes like below.
<p class="site-title">
<a href="@Url.Action("Index", "Home")">
<img src="your/img/path.jpg" alt="" />
</a>
</p>
For MVC layout page, you can implement it, in this below mentioned way:
<div class="navbar-header">
<div class="navbar-header pull-left">
<a class="navbar-brand" href="@Url.Action("Index", "Home")">
<img src="~/Images/Logo.jpg" alt="Site Logo" style="height:25px; width: 25px" /></a>
</div>
<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>
</button>
@Html.ActionLink("Application Name", "Index", "Home", null, new { @class = "navbar-brand" })
</div>
You can style it, the way you want.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With