Replace InsertImage with a new one?

Last post 11-21-2007, 11:28 AM by julgus. 4 replies.
Sort Posts: Previous Next
  •  11-21-2007, 9:38 AM 35271

    Replace InsertImage with a new one?

    Hi
    I want to replace the existing funtion InsertImage.php with a new one. I have just tested to fill a field called TargetUrl with a value and after that call the existing function do_insert().
     
    I end up with javascript error saying that TargetUrl has no properties.
     
    I use the javascript files used in the original InsertImage for init of the Javascript needed.
     
    Does it exist a guide how to implement a own InsertImage or can you please help me with this as this final step would complete my application.
     
    What data/fields do I have to update with a value before I can call do_insert?
     
    Best regards
    Johan
  •  11-21-2007, 9:45 AM 35272 in reply to 35271

    Re: Replace InsertImage with a new one?

    Johan,
     
    Are you modifying the existing dialog or create a separate dialog?
     
    The easiest solution for you is creating your own inert image dialog. Example:
     
     
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  11-21-2007, 9:55 AM 35273 in reply to 35272

    Re: Replace InsertImage with a new one?

    Adam, thanks for a quick reply. I can probably use the customdialog ! I'll try!
    Best regards
    Johan
     
     
  •  11-21-2007, 10:24 AM 35275 in reply to 35273

    Re: Replace InsertImage with a new one?

    Hi again
     
    As you can see below I opens a subwindow with a .php function.
     
    if(command=="MyCmd")
    {
     popUpWin('../gemensam/tst.php','600','600','bild',false);
    return true;
    }
     
    The last thing I'd like to do from tst.php is to write something into the editor.. I tried this:
    <script>
    window.parent.editor1.PasteHTML("keso");
    </script>
     
    but it didnt work. Error parent.editor1.PasteHTML("keso"); is null or not an object.
     
    Regards
    Johan
     
  •  11-21-2007, 11:28 AM 35277 in reply to 35275

    Re: Replace InsertImage with a new one?

    Solution:
    opener.editor1.PasteHTML("keso");
     
    Regards
View as RSS news feed in XML