Mac
Mac

Reputation: 7543

In firefox we cannot write anything on textbox of fileupload control while in Internet explorer we can why?

i have used fileupload control in my webpage but it show different behavior in internet explorer and firefox different behavior means in IE i can write anything on textbox, while firefox doesnot allow to do so why ? and how we can maintain consistency in both.

Upvotes: 1

Views: 453

Answers (2)

Nick Craver
Nick Craver

Reputation: 630559

In short, you should find another approach than messing with file inputs, this is in place for security reasons, for example to prevent you from changing the value to this on submit:

C:\MyPasswords.txt

Ignore the fact IE lets you mess with it at all, why are you changing the text in that input anyway? There should be an alternative approach to what you're after.

Upvotes: 1

Darin Dimitrov
Darin Dimitrov

Reputation: 1039130

The <input type="file" /> is a special tag which is rendered differently by browsers and you have no control over it and unfortunately there's not much you could do.

Upvotes: 1

Related Questions