Skip to content

Commit

Permalink
Contact-Page: Add Required-badge and use fieldset (#3418)
Browse files Browse the repository at this point in the history
* add required-badge and use fieldset
* use url helper and include antiforgerytoken inside the fieldset
  • Loading branch information
robertmuehsig authored and ryuyu committed Jan 31, 2017
1 parent 23e8ff6 commit 48cfd9b
Showing 1 changed file with 18 additions and 15 deletions.
33 changes: 18 additions & 15 deletions src/NuGetGallery/Views/Pages/Contact.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -51,21 +51,24 @@
</p>
using (Html.BeginForm("Contact", "Pages"))
{
@Html.AntiForgeryToken()
<div class="form-field">
@Html.LabelFor(m => m.SubjectLine)
@Html.TextAreaFor(m => m.SubjectLine, 1, 50, null)
</div>
<div class="form-field">
@Html.LabelFor(m => m.Message)
@Html.TextAreaFor(m => m.Message, 10, 50, null)
@Html.ValidationMessageFor(m => m.Message, null, new { id = "contact-support-message" })
</div>
<div class="form-field">
@Html.CheckBoxFor(m => m.CopySender)
@Html.LabelFor(m => m.CopySender, new { @class = "checkbox" })
</div>
<input id="form-submit" type="submit" value="Contact" title="Contact Support" />
<fieldset class="form">
@Html.AntiForgeryToken()
<div class="form-field">
@Html.LabelFor(m => m.SubjectLine)
@Html.TextAreaFor(m => m.SubjectLine, 1, 50, null)
</div>
<div class="form-field">
@Html.LabelFor(m => m.Message)
@Html.TextAreaFor(m => m.Message, 10, 50, null)
@Html.ValidationMessageFor(m => m.Message, null, new { id = "contact-support-message" })
</div>
<div class="form-field">
@Html.CheckBoxFor(m => m.CopySender)
@Html.LabelFor(m => m.CopySender, new { @class = "checkbox" })
</div>
<img src="@Url.Content("~/Content/images/required.png")" alt="Blue border on left means required.">
<input id="form-submit" type="submit" value="Contact" title="Contact Support" />
</fieldset>
}
}
else
Expand Down

0 comments on commit 48cfd9b

Please sign in to comment.