bergie / hallo

Simple rich text editor (contentEditable) for jQuery UI
http://hallojs.org/
MIT License
2.43k stars 318 forks source link

Programmatically put an element in edit mode #181

Open xolvio opened 11 years ago

xolvio commented 11 years ago

In my app, when a user drags and drops an element, I want to put that element in edit mode. I'd like to do this in the onDrop event. How can I get hallo to go into edit mode for an element that has had $(element).hallo() called on it?

I've seen a similar StackOverflow issue here and have tried to do the same and it's not working. Here's a JSFiddle

bx2 commented 11 years ago

@xolvio isn't that enough to put $element.hallo({ editable: true }); while by default initing the editor with editable flag set to false ?