0
Follows code:
_Layout:
<div class="navbar-collapse collapse">
<li>@Html.ActionLink("Início", "Index", "Home", new { @onmouseover = "this.style.color='#5cb85c';", @onmouseout = "this.style.color='';" })</li>
<li>@Html.ActionLink("Sobre", "About", "Home")</li>
<li>@Html.ActionLink("Contato", "Contact", "Home")</li>
</div>
View:
@using (Html.BeginForm("Upload", "Upload", FormMethod.Post, new { enctype = "multipart/form-data" }))
{
@Html.ValidationSummary(true)
<a id="voltar_pagina">Outra página</a>
}
JS:
$("#voltar_pagina").click(function () {
window.location = '/Pagina/Tipo'
});
Problem:
When I click Outra página
(Type B), the line <li>@Html.ActionLink("Início", "Index", "Home")</li>
(Type A) loses. It modifies the line to Tipo/Pagina?Length=9
.
Any solution? Because I’m not seeing the problem.
UPDATE:
I’ve tried that way and the problem continues:
<button type="button" onclick="location.href='@Url.Action("Tipo", "Pagina")'" >Outra página</button>
Follows Photo: