0

I have found the lot and got one editor which i use in my project (Flex Web application).

I have used CKEditor from this link.

<ckeditor:CKEditor id="editor1" width="100%" height="100%">
        <ckeditor:htmlText>
            <![CDATA[

            ]]>
        </ckeditor:htmlText>
</ckeditor:CKEditor>

It's working ok in my project. But, there is one issue i am facing.

Problem:
I have one alert message and Custom popup container. I want to display that both on top of the editor. But it hide behind the editor.

I want to display on top of that editor. How can i do this?

Currently look something like:

enter image description here

enter image description here

Thanks.

ketan
  • 19,129
  • 42
  • 60
  • 98

2 Answers2

1

I don't think that will be possible because the CKEditor area is drawn over the swf. So you can do, unfortunately, nothing.

Take a look on your html page source code and you'll see what I mean.

Edit :

I agree with @fsbmain about using ExternalInterface, but to show a JavaScript alert :

if(ExternalInterface.available){
    ExternalInterface.call('alert', 'some message here !');
}

Edit 2 :

To hide your CKEditor, you can use a JavaScript function which you can call via ExternalInterface :

JS :

<script type="text/javascript">     
    function hideCKEditor()
    {
        document.getElementById('ck0').style.display = 'none';
    }       
</script>

Then in the ActionScript side :

if(ExternalInterface.available){
    ExternalInterface.call('hideCKEditor');
}

Alert.show('Your message here !', 'Alert Box', mx.controls.Alert.OK);

Hope that can help.

akmozo
  • 9,829
  • 3
  • 28
  • 44
  • I have not only 1 alert message. I have another popup Container. Which should also be display on editor. – ketan Nov 03 '15 at 04:24
  • If this is not possible then there is any other good editor available which will work like flex component. – ketan Nov 03 '15 at 04:24
  • @ketan But, what about using JavaScript alerts ? Then if you've another question, it's better to post a new question. – akmozo Nov 03 '15 at 10:27
  • I can not use javascript alert. I have already mention that i am using another popup also. I have added screenshot in my question. – ketan Nov 03 '15 at 11:26
  • I use `visible ="false"` to hide the editor than also it is not working. – ketan Nov 03 '15 at 12:10
1

That editor based on html div (so it's a html element above your swf app), that means that you have only three options to show your popup "over" it:

  1. Hide editor when popup is opened - in my mind best option by risks/time ratio

Actually all other methods are dirty cheats and require quite a lot of work with questionable result with a lot of edge cases and potential issues:

  1. Show you popup in separate swf above that html, communicate between two swf with ExternalInterface
  2. Improve on #1 if you really want to show editor in background - make your editor screenshot with JS (try that Using HTML5/Canvas/JavaScript to take screenshots), send data to flash via ExternalInterface and display it in Bitmap
Community
  • 1
  • 1
fsbmain
  • 5,267
  • 2
  • 16
  • 23
  • I have not only 1 alert message. I have another popup Container. Which should also be display on editor. – ketan Nov 03 '15 at 04:24
  • If this is not possible then there is any other good editor available which will work like flex component. – ketan Nov 03 '15 at 04:25
  • I use `visible = "false"` to hide the editor than also it is not working. – ketan Nov 03 '15 at 12:10
  • with the same functional as html editor - no, afaik most of editors are quite simple like flex rich text editor and allows you to only edit simple text formatting – fsbmain Nov 05 '15 at 10:36