Advertisement
Guest User

Untitled

a guest
Jan 21st, 2013
129
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.42 KB | None | 0 0
  1. @model MVCPortfolio.Models.Post
  2.  
  3. @{
  4.     ViewBag.Title = "Create";
  5. }
  6. <h2>Create</h2>
  7.  
  8. @using (Html.BeginForm()) {
  9.     @Html.ValidationSummary(true)
  10.  
  11.     <fieldset>
  12.         <legend>Post</legend>
  13.  
  14.         <div class="editor-label">
  15.             @Html.LabelFor(model => model.Title)
  16.         </div>
  17.         <div class="editor-field">
  18.             @Html.EditorFor(model => model.Title)
  19.             @Html.ValidationMessageFor(model => model.Title)
  20.         </div>
  21.  
  22.         <div class="editor-label">
  23.             @Html.LabelFor(model => model.Date)
  24.         </div>
  25.         <div class="editor-field">
  26.             @Html.EditorFor(model => model.Date)
  27.             @Html.ValidationMessageFor(model => model.Date.Date)
  28.         </div>
  29.  
  30.         <div class="editor-label">
  31.             @Html.LabelFor(model => model.Tags)
  32.         </div>
  33.         <div class="editor-field">
  34.             @Html.EditorFor(model => model.Tags)
  35.             @Html.ValidationMessageFor(model => model.Tags)
  36.         </div>
  37.  
  38.         <div class="editor-label">
  39.             @Html.LabelFor(model => model.Content)
  40.         </div>
  41.         <div class="editor-field">
  42.             @Html.EditorFor(model => model.Content)
  43.             @Html.ValidationMessageFor(model => model.Content)
  44.         </div>
  45.  
  46.         <p>
  47.             <input type="submit" value="Create" />
  48.         </p>
  49.     </fieldset>
  50. }
  51.  
  52. <div>
  53.     @Html.ActionLink("Back to List", "Index")
  54. </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement