Button creation javascript error in IE7

Button creation javascript error in IE7

Creating a button in IE7 fails when I try to set the type to "button".

See below examples:
  1. $("body").append( $("<button/>", {"id": "save", "type": "button"}).html( "Save" ) );
  2. $("body").append( $("<button/>", {"id": "save"}).html( "Save" ) );
    $("#save").attr( "type", "submit" );
IE reports that the "Object doesn't support this action" for #1 and "Exception thrown and not caught" for #2.