Here is an issue bug report for media file browser upload form in IE browser (7,8).
When we tried to add or edit an image field from our local, the upload made successfully, but we can not edit any text field anymore.
Here is the js error below:

Webpage error details

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 2.0.50727; MS-RTC LM 8; .NET CLR 1.1.4322; .NET CLR 3.0.04506.30; .NET CLR 3.0.04506.648; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)
Timestamp: Tue, 30 Oct 2012 06:11:27 UTC

Message: Object expected
Line: 113
Char: 36
Code: 0
URI: http://localhost/media/browser?render=media-popup&fid=9

Add plus, when we use the media file library to change the image, it works fine.

CommentFileSizeAuthor
#3 media-file-browser-fix-ie.patch950 bytesavenhe
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

avenhe’s picture

Same issue.
When we use media file browser to upload an image/file field in IE (7,8), the file can be uploaded successfully . but we can not edit any text field anymore.

That is because we the focus for the text field in IE browser when upload successfully . When we click on the text field , we can not type any text and it lose focus on IE. But when we click the label for text field , the text field return focus. I don`t know why but it just happens.

Any one help?

kamkejj’s picture

I am having the same issue in IE 8 with media-2.0-unstable6.

After uploading an image I am unable to select a text field to add/edit text such as Alt Text or any other text field. After clicking the label for the text field I am then able to edit the field and any other text field.

avenhe’s picture

Here is the patch

ParisLiakos’s picture

Version: 7.x-1.2 » 7.x-1.x-dev
Status: Active » Needs review

correcting status

Status: Needs review » Needs work

The last submitted patch, media-file-browser-fix-ie.patch, failed testing.

arsau’s picture

Same issue.
There is also another bug linked to this one : a css bug.
After upload in IE, the field that follow the media one finds itself "under" the media image.
This cause by the property "height:auto" of the image. This property must be on it's parent container.

I made these two corrections but I don't know how to make patch and I don't use git.
I just could make the following svn diff:

Index: js/media.js
===================================================================
--- js/media.js
+++ js/media.js
@@ -48,8 +48,6 @@
fidField.trigger('change');
// Set the preview field HTML.
previewField.html(mediaFile.preview);
+ // Set the focus on window (because IE lost it after upload).
+ $(window).focus();
}, globalOptions);
e.preventDefault();
});

Index: css/media.css
===================================================================
--- css/media.css
+++ css/media.css
@@ -70,12 +70,12 @@
border: 1px solid #CCCCCC;
padding: 5px;
position: relative;
+ height: auto;
}

.media-item img {
- height: auto;
margin-bottom: 10px;
}

How can I give my solution ?
Thanks.

rteijeiro’s picture

Same problem here but both proposed solutions doesn't solve the problem.

Working in a new solution for that.

rteijeiro’s picture

It seems there is a solution in #1947094: Closing Media Browser dialog with Escape causes orphaned HTML to hang around

The patch doesn't apply so I did the changes manually and everything seems working well now. Tested in IE7.

EDIT: Patch applies well in the 7.x-2.x-dev version

aaron’s picture

Status: Needs work » Closed (duplicate)
avenhe’s picture

aaa