Custom File Storage for images and files

Last post 07-18-2006, 11:24 AM by rchen. 1 replies.
Sort Posts: Previous Next
  •  06-19-2006, 12:27 PM 20268

    Custom File Storage for images and files

    Hi, here is my problem:
     
    I have a separate storage for image and documents.  Their starting path is different and the way to retrieve the content is also different.  I am using Microsoft CMS as the storage for the images (in Resources) and documents (in Channel).  I have coded a customFileStorage class following the example provided for the SQL Database.  It works.  However, I have the following 2 questions:
     
    1. Now, this customFileStorage class is set to setting["CuteEditorFileStorageType"] and is sharing for both inserting images and dowonloaded document.  Is there a way that I can set separate classes for images and documents?
     
    2. If the above is impossible, is there a way for me to know which icon is actually being clicked (insert image or downloadable files).  That way I can have some logic in my customFileStorage class to do different things.
     
    Please someone help me with this.  This is really urgent.
     
    Thank you very much,
     
    Richard
  •  07-18-2006, 11:24 AM 21021 in reply to 20268

    Re: Custom File Storage for images and files

    I am now trying to use the custom button to open an aspx page to mimic the behaviour of insert file dialog.  However, whenever there is a postback happening on the aspx page, it is opening a new window and try to do the postback in the new window, which fails.
     
    I am using the javascript function to open the dialog:
     
    function ShowMyDialog(button) { //use CuteEditor_GetEditor(elementinsidetheEditor) to get the cute editor instance var editor=CuteEditor_GetEditor(button); //show the dialog page , and pass the editor as newwin.dialogArguments var newwin=showModalDialog("DocumentSelectionPage.aspx" ,editor,""); }
     
    Can anyone let me know how I can make the post back works?
     
    Thanks,
     
    Richard
View as RSS news feed in XML