[CLOSED] AntiForgeryToken

  1. #1

    [CLOSED] AntiForgeryToken

    Is there a way to add the Html.AntiForgeryToken() to a Html.X().FormPanelFor?
    Last edited by Daniil; Feb 12, 2013 at 9:26 AM. Reason: [CLOSED]
  2. #2
    Hi @jpadgett,

    We could not see an easy way to accomplish it, but we would try the following.

    Html.AntiForgeryToken() generates a string representing an HTML hidden field. You could cut that hidden field's value from that string using a regular expression. Then put this value into an Ext.NET Hidden field (respectively, putting that HiddenField into the FormPanelFor's Items).
  3. #3
    Hi,

    AntiForgeryField MVC helper is added to SVN, now you can use it like
    @Html.X().AntiForgeryField()
  4. #4
    Great! Thank you!

Posting Permissions