title: how to execute Ajax request if javascript is enabled, otherwise, request will be by POSTBACK?
body: <p>I am a beginner at MVC.</p>
  
  <p>I wrote a code that displays the software list as Ajax request. But when the javascript in browser is disabled or not supported, the code output will be broken and will be displayed as long strings.</p>
  
  <p>How can I handle this state?</p>
  
  <p>If javascript is enabled, Ajax code will be executed otherwise, request will be sent by POSTBACk request.</p>
  
  <p>this my code:</p>
  
  <pre><code>@model string
  @{
  AjaxOptions AjaxOpts=new AjaxOptions{
      UpdateTargetId="tabledata"
      };
  }
  @using(Ajax.BeginForm("ListData",AjaxOpts)){
  &lt;table&gt;
    &lt;thead&gt;
      &lt;th&gt;Client Name&lt;/th&gt;
      &lt;td&gt;dates&lt;/th&gt;
    &lt;/thead&gt;
  &lt;tbody id="tabledata"&gt;
      @Html.Action("ListData",new {id=Model})
  &lt;/tbody&gt;
  &lt;/table&gt;
  &lt;p&gt;
      @Html.DropDownList("id",new SelectList(
      new[]{"All","web","Windows"},(Model??"All")))
  &lt;input typr="submit" value="Submit"/&gt;
  &lt;/p&gt;
  }
  </code></pre>
  
  <p>please guide me</p>