alim Posted October 30, 2007 Share Posted October 30, 2007 with help this command i can put a string insted of a selected one :tinyMCE.execCommand('mceInsertRawHTML', false, "blabla");but i can delete this string insinde the Tiny editor with the Del Button ( Keyboard ) ! How can make it undeletable or unchangeable ??? Does anybody have an idea ? Link to comment Share on other sites More sharing options...
Jesdisciple Posted October 30, 2007 Share Posted October 30, 2007 You could make it private within a custom object, but the custom object can still be deleted (if someone knows its name): function CustomObject(string){ this.getString = function(){ return string; };}var myObj = new CustomObject('my private string');alert(myObj.getString()); Link to comment Share on other sites More sharing options...
justsomeguy Posted October 30, 2007 Share Posted October 30, 2007 He's asking about a user-interface question. You can't stop someone from hitting the delete or backspace key or any other key to overwrite selected text. You can write the text into an element that does not allow editing though, like a div. Or you can check for a keypress and reset to text to whatever it was before they hit the key. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.