$(form).submit not working in any IE version
<p>I have a upload file function that triggers a form submit event after the file has been choosed, however the function doesn't seem to trigger that event in any IE version.</p>

<pre><code>    var fromPCFunc = function() {
    var Iframe = '&lt;iframe id="uploadiframe"&gt;&lt;/iframe&gt;',
        formElement = '&lt;form name="uploadForm" style="display:none;" enctype="multipart/form-data" method="post" action="scripts/imageUpload.php" target="uploadiframe"&gt;',
        fileField = '&lt;input name="imageFile"  type="file" value="" /&gt;';

    $('body').append(formElement);
    $('form[name="uploadForm"]').append(fileField);
    $('body').append(Iframe);
    $('iframe#uploadiframe').css('display', 'none');

    $('form[name="uploadForm"]').find('input[name="imageFile"]').click(function() {
        this.value = "";
    });
    $('form[name="uploadForm"]').find('input[name="imageFile"]').click();

    $(window).focus(function() {
        if ($('form[name="uploadForm"]').find('input[name="imageFile"]')[0].value === "") {
            $('iframe#uploadiframe').remove();
            $('form[name="uploadForm"]').remove();
        } else {
            $('#imageEditor_mainImage').trigger('imgLoading');
            $('form[name="uploadForm"]').submit();
        }
        $(this).unbind('focus');
    });

    $('iframe#uploadiframe').load(function() {
        var _this = this;
        removeFunc = function() {
            var imageFile = $.trim($(_this).contents().find('body').text());
            $('#imageEditor_mainImage').trigger('imageOpen', imageFile);
            $(_this).remove();
            $('form[name="uploadForm"]').remove();
        }
        removeFunc();
    });
}
</code></pre>

<p>Is there any way to fix this? Thanks in advanced.</p>
