Permalink
Browse files

bootstrap top menu added

  • Loading branch information...
1 parent 92c6a42 commit 66d7c8c975fe9d87dc6812a0486292a64a538e39 @akurdyukov committed May 10, 2012
@@ -82,7 +82,9 @@
<ItemGroup>
<None Include="app.config" />
<None Include="packages.config" />
- <None Include="Views\layout.cshtml" />
+ <None Include="Views\MainLayout.cshtml">
+ <CopyToOutputDirectory>Always</CopyToOutputDirectory>
+ </None>
<None Include="Views\login.cshtml">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>Some Application</title>
+ <link href="@Url.Content("/assets/bootstrap/css/bootstrap.css")" rel="stylesheet"/>
+ @RenderSection("Header", required: false)
+</head>
+ <body>
+ <div class="navbar navbar-fixed-top">
+ <div class="navbar-inner">
+ <div class="container">
+ <a class="brand" href="@Url.Content("/")">Project name</a>
+ <div class="nav-collapse collapse">
+ <ul class="nav">
+ <li class="">
+ <a href="./index.html">Overview</a>
+ </li>
+ </ul>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="container">
+ <div class="content">
+ @RenderBody()
+ </div>
+ </div>
+ </body>
+</html>
@@ -1,15 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
- <title>Some Application</title>
- <link href="@Url.Content("/assets/bootstrap/css/bootstrap.css")" rel="stylesheet"/>
- @RenderSection("header", optional: true)
-</head>
-<body>
- <div class="container">
- <div class="content">
- @RenderBody()
- </div>
- </div>
-</body>
-</html>
@@ -1,8 +1,8 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
- <title>Login</title>
- <link href="@Url.Content("/assets/bootstrap/css/bootstrap.css")" rel="stylesheet"/>
+@{
+ Layout = "MainLayout";
+}
+
+@section Header {
<style type="text/css">
/* Override some defaults */
html, body
@@ -44,34 +44,28 @@
color: #404040;
}
</style>
-</head>
-<body>
- <div class="container">
- <div class="content">
- <div class="row">
- <div class="login-form">
- <h2>Login</h2>
- <form method="POST">
- <fieldset>
- @if (Model.Errored)
- {
- <div class="alert alert-error">Invalid Username or Password</div>
- }
- <div class="clearfix">
- <input type="text" placeholder="Username" name="Username"/>
- </div>
- <div class="clearfix">
- <input type="password" placeholder="Password" name="Password"/>
- </div>
- <div>
- Remember Me <input name="RememberMe" type="checkbox" value="True" />
- </div>
- <button class="btn btn-primary" type="submit">Sign in</button>
- </fieldset>
- </form>
- </div>
+}
+
+<div class="row">
+ <div class="login-form">
+ <h2>Login</h2>
+ <form method="POST">
+ <fieldset>
+ @if (Model.Errored)
+ {
+ <div class="alert alert-error">Invalid Username or Password</div>
+ }
+ <div class="clearfix">
+ <input type="text" placeholder="Username" name="Username"/>
</div>
- </div>
+ <div class="clearfix">
+ <input type="password" placeholder="Password" name="Password"/>
+ </div>
+ <div>
+ Remember Me <input name="RememberMe" type="checkbox" value="True" />
+ </div>
+ <button class="btn btn-primary" type="submit">Sign in</button>
+ </fieldset>
+ </form>
</div>
-</body>
-</html>
+</div>
@@ -1,13 +1,9 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
- <title>Secure Page!</title>
-</head>
-<body>
- Welcome to the secure area @Model.Username ! @Model.Id
+@{
+ Layout = "MainLayout";
+}
- <br />
- <br />
- <a href="@Url.Content("~/logout")">Logout</a>
-</body>
-</html>
+Welcome to the secure area @Model.Username ! @Model.Id
+
+<br />
+<br />
+<a href="@Url.Content("~/logout")">Logout</a>

0 comments on commit 66d7c8c

Please sign in to comment.