Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Jul 4th, 2011  |  syntax: None  |  size: 1.38 KB  |  views: 63  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. @model FirstWeb.Models.Picture
  2.  
  3. @{
  4.     ViewBag.Title = "Upload et billede";
  5.    
  6. }
  7.  
  8. <h2>Upload et billede</h2>
  9.  
  10. <script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
  11. <script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
  12.  
  13.  
  14.  
  15. @using (Html.BeginForm()) {
  16.     @Html.ValidationSummary(true)
  17.     <fieldset>
  18.        
  19.         <div class="editor-label">
  20.             @Html.Label("Titel")
  21.         </div>
  22.         <div class="editor-field">
  23.             @Html.EditorFor(model => model.Title)
  24.             @Html.ValidationMessageFor(model => model.Title)
  25.         </div>
  26.  
  27.         <div>
  28.             @Html.Label("Billede")
  29.         </div>
  30.  
  31.         <div>
  32.             @using (Html.BeginForm(null, null, FormMethod.Post, new { enctype = "multipart/form-data" }))
  33.             {
  34.                 <input type="file" name="file" id="File" />
  35.             }
  36.             </div>
  37.  
  38.         <div class="editor-label">
  39.             @Html.Label("Koncert år")
  40.         </div>
  41.         <div class="editor-field">
  42.             @Html.EditorFor(model => model.ConcertYear)
  43.             @Html.ValidationMessageFor(model => model.ConcertYear)
  44.         </div>
  45.         <p>
  46.             <input type="submit" value="Upload" />
  47.         </p>
  48.     </fieldset>
  49. }
  50.  
  51. <div>
  52.     @Html.ActionLink("Tilbage til billeder", "Index")
  53. </div>