Advertisement
Guest User

Untitled

a guest
Jun 20th, 2015
314
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.47 KB | None | 0 0
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8" />
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <title>@ViewBag.Title - My ASP.NET Application</title>
  7. @Styles.Render("~/Content/css")
  8. <script src="@Url.Content("~/js/jquery-1.10.2.min.js")" type="text/javascript"></script>
  9. <script src="@Url.Content("~/js/jquery-ui.js")" type="text/javascript"></script>
  10. <script src="@Url.Content("~/js/ckeditor.js")" type="text/javascript"></script>
  11. <script src="@Url.Content("~/ckeditor/adapters/jquery.js")" type="text/javascript"></script>
  12. @Scripts.Render("~/bundles/modernizr")
  13.  
  14. <script type="text/javascript">
  15. $(function () {
  16.  
  17. $('#noidung').ckeditor
  18. });
  19.  
  20. </script>
  21.  
  22. </head>
  23. <body>
  24. <div class="navbar navbar-inverse navbar-fixed-top">
  25. <div class="container">
  26. <div class="navbar-header">
  27. <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
  28. <span class="icon-bar"></span>
  29. <span class="icon-bar"></span>
  30. <span class="icon-bar"></span>
  31. </button>
  32. @Html.ActionLink("Application name", "Index", "Home", new { area = "" }, new { @class = "navbar-brand" })
  33. </div>
  34. <div class="navbar-collapse collapse">
  35. <ul class="nav navbar-nav">
  36. <li>@Html.ActionLink("Home", "Index", "Home")</li>
  37. <li>@Html.ActionLink("About", "About", "Home")</li>
  38. <li>@Html.ActionLink("Contact", "Contact", "Home")</li>
  39. </ul>
  40. @Html.Partial("_LoginPartial")
  41. </div>
  42. </div>
  43. </div>
  44. <div class="container body-content">
  45. @RenderBody()
  46. <hr />
  47. <footer>
  48. <p>&copy; @DateTime.Now.Year - My ASP.NET Application</p>
  49. </footer>
  50. </div>
  51.  
  52. @Scripts.Render("~/bundles/jquery")
  53. @Scripts.Render("~/bundles/bootstrap")
  54. @RenderSection("scripts", required: false)
  55.  
  56. </body>
  57. </html>
  58.  
  59. @model OffLogWeb.BanGhi
  60.  
  61. @{
  62. ViewBag.Title = "Create";
  63. Layout = "~/Views/Shared/_Layout.cshtml";
  64. }
  65. <h2>Create</h2>
  66.  
  67.  
  68.  
  69. @using (Html.BeginForm())
  70. {
  71. @Html.AntiForgeryToken()
  72.  
  73. <div class="form-horizontal">
  74. <h4>BanGhi</h4>
  75. <hr />
  76. @Html.ValidationSummary(true, "", new { @class = "text-danger" })
  77. <div class="form-group">
  78. @Html.LabelFor(model => model.Ngay, htmlAttributes: new { @class = "control-label col-md-2" })
  79. <div class="col-md-10">
  80. @Html.EditorFor(model => model.Ngay, new { htmlAttributes = new { @class = "form-control", @id = "ngay" } })
  81. @Html.ValidationMessageFor(model => model.Ngay, "", new { @class = "text-danger" })
  82. </div>
  83. </div>
  84.  
  85. <div class="form-group">
  86. @Html.LabelFor(model => model.Gio, htmlAttributes: new { @class = "control-label col-md-2" })
  87. <div class="col-md-10">
  88. @Html.EditorFor(model => model.Gio, new { htmlAttributes = new { @class = "form-control" } })
  89. @Html.ValidationMessageFor(model => model.Gio, "", new { @class = "text-danger" })
  90. </div>
  91. </div>
  92.  
  93. <div class="form-group">
  94. @Html.LabelFor(model => model.Phut, htmlAttributes: new { @class = "control-label col-md-2" })
  95. <div class="col-md-10">
  96. @Html.EditorFor(model => model.Phut, new { htmlAttributes = new { @class = "form-control" } })
  97. @Html.ValidationMessageFor(model => model.Phut, "", new { @class = "text-danger" })
  98. </div>
  99. </div>
  100.  
  101. <div class="form-group">
  102. @Html.LabelFor(model => model.TieuDe, htmlAttributes: new { @class = "control-label col-md-2" })
  103. <div class="col-md-10">
  104. @Html.EditorFor(model => model.TieuDe, new { htmlAttributes = new { @class = "form-control" } })
  105. @Html.ValidationMessageFor(model => model.TieuDe, "", new { @class = "text-danger" })
  106. </div>
  107. </div>
  108.  
  109. <div class="form-group">
  110.  
  111. <div class="col-md-10">
  112. @Html.LabelFor(model => model.NoiDung, htmlAttributes: new { @class = "control-label col-md-2" })
  113. <div class="col-md-10">
  114.  
  115. @Html.TextArea("editor1", Model.NoiDung,new {id="editor1",@name="editor1" })
  116. </div>
  117. <script>
  118. //Replace the <textarea id="editor1"> with an CKEditor instance.
  119. CKEDITOR.replace('editor1', {
  120. on: {
  121. focus: onFocus,
  122. blur: onBlur,
  123.  
  124. // Check for availability of corresponding plugins.
  125. pluginsLoaded: function (evt) {
  126. var doc = CKEDITOR.document, ed = evt.editor;
  127. if (!ed.getCommand('bold'))
  128. doc.getById('exec-bold').hide();
  129. if (!ed.getCommand('link'))
  130. doc.getById('exec-link').hide();
  131. }
  132. }
  133. });
  134. </script>
  135. </div>
  136. </div>
  137. <div class="form-group">
  138. @Html.LabelFor(model => model.Tot, htmlAttributes: new { @class = "control-label col-md-2" })
  139. <div class="col-md-10">
  140. <div class="checkbox">
  141. @Html.EditorFor(model => model.Tot)
  142. @Html.ValidationMessageFor(model => model.Tot, "", new { @class = "text-danger" })
  143. </div>
  144. </div>
  145. </div>
  146.  
  147. <div class="form-group">
  148. @Html.LabelFor(model => model.Diem, htmlAttributes: new { @class = "control-label col-md-2" })
  149. <div class="col-md-10">
  150. @Html.EditorFor(model => model.Diem, new { htmlAttributes = new { @class = "form-control" } })
  151. @Html.ValidationMessageFor(model => model.Diem, "", new { @class = "text-danger" })
  152. </div>
  153. </div>
  154.  
  155. <div class="form-group">
  156. <div class="col-md-offset-2 col-md-10">
  157. <input type="submit" value="Create" class="btn btn-default" />
  158. </div>
  159. </div>
  160. </div>
  161. }
  162.  
  163. <div>
  164. @Html.ActionLink("Back to List", "Index")
  165. </div>
  166.  
  167. @section Scripts {
  168. @Scripts.Render("~/bundles/jqueryval")
  169. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement