title: Why can't I change the type of an input element to submit?
body: <p>I'm calling this function:</p>
  
  <pre><code>function submit_button(button_id){
      $('#' + button_id).attr('type', 'submit');
  }
  </code></pre>
  
  <p>to make this button type = submit instead of button.:</p>
  
  <pre><code>&lt;input  name="confirm_button" id="confirm_button" type="button" value="Confirm" class="login_btn" /&gt;
  </code></pre>
  
  <p>and I get this error (in firefox):</p>
  
  <p>uncaught exception: type property can't be changed</p>
  
  <p>Are there any work arounds?</p>