javascript is executing in IE

Last post 11-02-2011, 7:54 AM by Kenneth. 9 replies.
Sort Posts: Previous Next
  •  10-19-2011, 7:22 PM 70482

    javascript is executing in IE

    My editor creates html pages.
     
    I have a simple redirect javascript, when i try to open my html page in the editor, the editor window redirects to the destination URL. I can no longer edit the source code.
     
    Working in FF, NOT WORKING IN IE 
  •  10-20-2011, 9:56 AM 70488 in reply to 70482

    Re: javascript is executing in IE

    Hi cosmonaut,
     
    Can you show me the code of your html page? So we can check it for you.
     
    Do you get the same issue on demo http://phphtmledit.com/EnableAll.php?
     
    Regards,
     
    Ken
  •  10-21-2011, 5:53 PM 70510 in reply to 70488

    Re: javascript is executing in IE

    yes, can replicate this issue WITH IE on your demo page.
     
    just insert this code in HTML mode:
    <script type="text/javascript">
    window.location = "http://www.google.com"
    </script> 
     
    and then click the 'Save' icon. IE will redirect to google.com 
  •  10-24-2011, 1:44 AM 70517 in reply to 70510

    Re: javascript is executing in IE

    Hi cosmonaut,
     
    Please try the example below, does it work for you?
     
    <?php require_once "cuteeditor_files/include_CuteEditor.php" ?>  

    <html>    
    <body>    
            <form id="form1" method="POST">    
                <?php    
                    $editor=new CuteEditor();    
                    $editor->Text="Type here";    
                    $editor->ID="Editor1";
                    $editor->Draw();    
                ?>    
           </form>    
    </body>    
    </html>
     
    On the demo page http://phphtmledit.com/EnableAll.php when you click on the save button, the page will post the content to http://phphtmledit.com/Get_HtmlContent.php, the script fired by this page (because the script added as the content in this page) not the editor.
     
    Regards,
     
    Ken
  •  10-26-2011, 2:42 PM 70533 in reply to 70517

    Re: javascript is executing in IE

    it executes the script in IE, the editor loads the redirect URL inside its frame:
     
    - - - - - - - - - - - - - 
     
    <?php require_once "../cuteeditor_files/include_CuteEditor.php" ?>  
    <html>    
    <body>    
            <form id="form1" method="POST">    
                <?php    
                    $editor=new CuteEditor();    
                    $editor->Text="<script>window.location='http://www.cutesoft.net';</script>";    
                    $editor->ID="Editor1"; 
                    $editor->Draw();    
                ?>    
           </form>    
    </body>    
    </html>
     
  •  10-27-2011, 7:29 AM 70538 in reply to 70533

    Re: javascript is executing in IE

    Hi cosmonaut,
     
    I tested your code, it still works fine for me on IE browser.
     
    Is your site online? If so, can you post the editor page url which using the code you provided? So we can check it for you.
     
    Regards,
     
    Ken
  •  10-27-2011, 10:28 AM 70542 in reply to 70538

    Re: javascript is executing in IE

    It's not a public facing page. But the behavior seems very easy to reproduce. It can even be done in FF, chrome, etc.
     
     
     
    with this code:
    <?php require_once "../cuteeditor_files/include_CuteEditor.php" ?>  
    <html>    
    <body>    
            <form id="form1" method="POST">    
                <?php    
                    $editor=new CuteEditor();    
                    $editor->Text="<script>window.location='http://www.cutesoft.net';</script>";    
                    $editor->ID="Editor1"; 
                    $editor->Draw();    
                ?>    
           </form>    
    </body>    
    </html>
     
     
    this is the result (loads cutesoft.net in the editor and then you cannot switch to any other view (html/preview): 
     
  •  10-28-2011, 7:25 AM 70551 in reply to 70542

    Re: javascript is executing in IE

    Hi cosmonaut,
     
    I still can not reproduce your issue.
     
    Can you show me your mail ID? I will send a flash movie to you to shows what I tested.
     
    The <script> code never fire in the editor, it just like the simpe content.
     
    Regards,
     
    Ken
  •  11-01-2011, 1:11 PM 70797 in reply to 70551

    Re: javascript is executing in IE

    kenneth,
    i sent you my email address in a private message last week. let me know, thanks!
  •  11-02-2011, 7:54 AM 70884 in reply to 70797

    Re: javascript is executing in IE

    Hi cosmonaut,
     
    Please send it to [email protected] directly.
     
    Regards,
     
    Ken
View as RSS news feed in XML