pradeep
pradeep

Reputation: 1057

Editable div not working on firefox

Hi i am using an dynamic div which is editable for input text. its working fine on IE but not on firefox. I need to show html content in div. can we make div editable for firefox also?

Upvotes: 0

Views: 594

Answers (1)

Martijn Laarman
Martijn Laarman

Reputation: 13536

Firefox requires the designMode to be set on an iFrame. The specification doesn't explicitly mention this but the following quote sort of implies it already

For example, in JavaScript, if you have an iframe with an id of 'edit', you can get its contentDocument and set designMode to "on" like this:

You will find alot of browser differences in how they handle designMode so be prepared and take it as a challenge or else you might lose a few hairs in the process.

Upvotes: 1

Related Questions