title: Disable client-side validation in MVC 4 submit button
body: <p>In my asp.net mvc4 app, I get this error "A potentially dangerous Request.Form value was detected from the client" for example when creating a new item "cond".
  cond is a table in the database with two fields "id_regle" and "cond_txt".
  The cond_txt fields will have conditions with the following form "left_side+op+right_side"; op= &lt;, >, == ....
  I tried different suggestions that I found, but non of them worked for me to disable this validation.</p>
  
  <p>This is the view "create":</p>
  
  <pre><code>@model MvcApplication3.cond
  @{
  ViewBag.Title = "Create";
  }
   &lt;h2&gt;Create&lt;/h2&gt;
  @using (Html.BeginForm()) {
  @Html.ValidationSummary(true)
  
  &lt;fieldset&gt;
      &lt;legend&gt;cond&lt;/legend&gt;
  
      &lt;div class="editor-label"&gt;
          @Html.LabelFor(model =&gt; model.cond_txt)
      &lt;/div&gt;
      &lt;div class="editor-field"&gt;
          @Html.EditorFor(model =&gt; model.cond_txt)
          @Html.ValidationMessageFor(model =&gt; model.cond_txt)
      &lt;/div&gt;
  
      &lt;div class="editor-label"&gt;
          @Html.LabelFor(model =&gt; model.id_regle, "regle")
      &lt;/div&gt;
      &lt;div class="editor-field"&gt;
          @Html.DropDownList("id_regle", String.Empty)
          @Html.ValidationMessageFor(model =&gt; model.id_regle)
      &lt;/div&gt;
  
      &lt;p&gt;
          &lt;input type="submit" value="Create" class="cancel" /&gt;
      &lt;/p&gt;
  &lt;/fieldset&gt;
  }
  &lt;div&gt;
  @Html.ActionLink("Back to List", "Index")
  &lt;/div&gt;
  @section Scripts {
  @Scripts.Render("~/bundles/jqueryval")
  }
  </code></pre>
  
  <p>And this is the controller:</p>
  
  <pre><code> public ActionResult Create()
      {
          ViewBag.id_regle = new SelectList(db.regle, "id", "action");
          return View();
      }
  
      //
      // POST: /Default2/Create
  
      [HttpPost]
      public ActionResult Create(cond cond)
      {
          if (ModelState.IsValid)
          {
              db.cond.AddObject(cond);
              db.SaveChanges();
              return RedirectToAction("Index");
          }
  
          ViewBag.id_regle = new SelectList(db.regle, "id", "action", cond.id_regle);
          return View(cond);
      }
  </code></pre>
  
  <p>I've tried adding validateRequest="false" in the web.config, but that didn't work for me
  Any suggestions plz</p>