Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8382441
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T16:55:45+00:00 2026-06-09T16:55:45+00:00

I have the following in my Razor view: @using (Html.BeginForm(Edit, MyController, FormMethod.Post)) { <div

  • 0

I have the following in my Razor view:

 @using (Html.BeginForm("Edit", "MyController", FormMethod.Post))
{
    <div class="grid_1">&nbsp;</div>
    <div id="ValSummary"> @Html.ValidationSummary(false)</div>


    @Html.EditorFor(x => x.Role, MVC.Shared.Views.EditorTemplates.KeyValuePairSelectList, new { SelectListOptions = Model.RoleSelectList })<br /><br />
    @Html.EditorFor(x => x.Trust, MVC.Shared.Views.EditorTemplates.KeyValuePairSelectList, new { SelectListOptions = Model.TrustSelectList.OrderBy(x => x.Text) })<br /><br />
    @Html.EditorFor(x => x.GmcCode)<br /><br />


    <div class="createbutton">
        <input id="btnGoBack" type="button" value="Back"/>  
        <input id="btnSubmit" type="button" value="Submit" />
    </div>

}

In my controller I have

[HttpGet]
public virtual ActionResult Edit(string id)
{
}

[HttpPost]
public virtual ActionResult Edit(ViewModel viewModel)
{
}

In Firefox and Chrome everything works fine but in IE when the form is submitted the HttpGet action is being fired rather than the HttpPost.

There are no clues in the call stack or from the IE developer tools console.

Anything obvious that I am missing?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T16:55:46+00:00Added an answer on June 9, 2026 at 4:55 pm

    Your Submit button should a real submit button with type="Submit"

    <input id="btnSubmit" type="submit" value="Submit" />
    

    to submit the form correctly in all browsers.

    See this SO questions for further differences: Difference between <input type='button' /> and <input type='submit' />

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using the razor view engine, I have some code like the following: @Html.TextAreaFor(model =>
In my html I have <h2>Title goes here</h2> @using (Html.BeginForm(Action, Controller, FormMethod.Post, new {
Using the following: MVC 3 VB.NET RAZOR VIEW engine Html Helper Class In my
I am trying to render the following HTML using an MVC3 Razor View: <input
This one is strange...I have the following markup for a view using Razor view
I'm using MVC3 with Razor. I have the following helper: public static class ImageActionLinkHelper
I have the following in my Razor view for an editor template in my
I have the following razor template html, although I can't figure out how to
I'm using MVC3's Razor engine to generate views and have the following line of
I have the following razor code: <form id=logon action=/security/dev method=get> @Html.AntiForgeryToken() @Html.EditorFor(x => x.UserName)

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.