#2751: Write fake object display and replacement logic for CKEditor v3
------------------------+---------------------------------------------------
  Reporter:  martinkou  |       Owner:  martinkou   
      Type:  Task       |      Status:  reopened    
  Priority:  High       |   Milestone:  CKEditor 3.0
 Component:  General    |     Version:              
Resolution:             |    Keywords:  Confirmed   
------------------------+---------------------------------------------------

Comment(by martinkou):

 The pseudocode you wrote should work. Basically, to process the fake
 object in the dialog, you need to:

  1. Get the placeholder element. You can get the currently selected
 placeholder element by looking for an <img> tag with with
 "_cke_protected_html" attribute, or having "_cke_fakeobject" in its class.
  2. Convert the placeholder element into the real element via
 CKEDITOR.plugins.fakeobjects.restoreElement().
  3. Process the real element (e.g. change its URL, change its size, etc.)
  4. Convert the real element back to a placeholder element and insert it
 to the editing area.

 So basically, the real element should never appear in the WYSIWYG area,
 it's where the placeholder element belongs to. The real element is only
 used when you need to process it or you need to get the HTML code output.

-- 
Ticket URL: <http://dev.fckeditor.net/ticket/2751#comment:5>
FCKeditor <http://www.fckeditor.net/>
The text editor for Internet
------------------------------------------------------------------------------
_______________________________________________
FCKeditor-Trac mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fckeditor-trac

Reply via email to