﻿@using Microsoft.AspNet.Identity


<div class="row">
    <div class="col-md-6">
        <h1>
            @ViewBag.Title
            <small>
                @ViewBag.Lead
            </small>
        </h1>
    </div>

    <div class="col-md-6">
        <ul class="nav nav-pills pull-right">
            @if (Request.IsAuthenticated)
            {
                using (Html.BeginForm("LogOff", "Account", FormMethod.Post, new { id = "logoutForm", @class = "navbar-right" }))
                {
                    @Html.AntiForgeryToken()

                    <li><a href="/">Home</a></li>
                    <li>
                        @Html.ActionLink("Hello " + User.Identity.GetUserName() + "!", "Index", "Manage", routeValues: null, htmlAttributes: new { title = "Manage" })
                    </li>
                    <li><a href="javascript:document.getElementById('logoutForm').submit()">Log off</a></li>
                }
            }
            else
            {
                <li><a href="/">Home</a></li>
                <li>@Html.ActionLink("Register", "Register", "Account", routeValues: null, htmlAttributes: new { id = "registerLink" })</li>
                <li>@Html.ActionLink("Log in", "Login", "Account", routeValues: null, htmlAttributes: new { id = "loginLink" })</li>
            }
        </ul>
    </div>
</div>
<br /><br />

﻿@using Microsoft.AspNet.Identity

@using (Html.BeginForm("LogOff", "Account", FormMethod.Post, new { id = "logoutForm", @class = "navbar-right" }))
{
    @Html.AntiForgeryToken()
}

<div class="row">
    <div class="col-md-6">
        <h1>
            @ViewBag.Title
            <small>
                @ViewBag.Lead
            </small>
        </h1>
    </div>

    <div class="col-md-6">
        <ul class="nav nav-pills pull-right">
            @if (Request.IsAuthenticated)
            {
                <li><a href="/">Home</a></li>
                <li>
                    @Html.ActionLink("Hello " + User.Identity.GetUserName() + "!", "Index", "Manage", routeValues: null, htmlAttributes: new { title = "Manage" })
                </li>
                <li>
                    <a href="javascript:document.getElementById('logoutForm').submit()">Log off</a>
                </li>
            }
            else
            {
                <li><a href="/">Home</a></li>
                <li>@Html.ActionLink("Register", "Register", "Account", routeValues: null, htmlAttributes: new { id = "registerLink" })</li>
                <li>@Html.ActionLink("Log in", "Login", "Account", routeValues: null, htmlAttributes: new { id = "loginLink" })</li>
            }
        </ul>
    </div>
</div>
<br /><br />

Fix logout form input button
Fix logout form input button
