Image Folder Other than under App Folder?

Last post 06-27-2007, 4:59 AM by carin. 4 replies.
Sort Posts: Previous Next
  •  06-21-2007, 9:20 AM 30950

    Image Folder Other than under App Folder?

    Hi all!

    Want to be able to select images from a virtual folder on the server, but one that doesn't sit under my app folder. So e.g. like this:

    App: servername/myapp
    Images: servername/imagelib

    Is this doable? I have tried to but can't get it to work.... Also tried to find a solution on this forum but couldn't so hope you can help me out.

    Help!

    Cheers,
    Carin

  •  06-21-2007, 11:52 AM 30963 in reply to 30950

    Re: Image Folder Other than under App Folder?

    Carin,
     
    It should work just make sure the about folder is configured as virtual directory.
     
     

    How to specify the Image gallery path?

    You can easily specify the image gallery path using the following methods:

    1: Edit security policy file:


    The security policy file (default.config, admin.config and guest.config) can be found in the /CuteEditor/Configuration/Security folder. In security policy file you can find the ImageGalleryPath element which contains the image gallery path information within CuteEditor.  By default, it contains the following value:


    <
    security name="ImageGalleryPath">~/uploads</security>
      

    You can modify the ImageGalleryPath element to meet your own requirements.

    For example:

    Use absolute path:

    <security name="ImageGalleryPath">/uploads</security>

     

    Use physical path:

    <security name="ImageGalleryPath">c:\inetpub\wwwroot\uploads</security>

     

    2: Programmatically specify the Image gallery path:


    C# Example:

    //use the app-based path 

    Editor1.Setting["security:ImageGalleryPath"]= "~/uploads";
    //use the absolute path 
    Editor1.Setting["security:ImageGalleryPath"]= "/uploads";
    //use the physical path 
    Editor1.Setting["security:ImageGalleryPath"]= @"c:\inetpub\wwwroot\uploads";
    or
    //use the app-based path 

    Editor1.SetSecurityImageGalleryPath("~/uploads");
    //use the absolute path 
    Editor1.SetSecurityImageGalleryPath("/uploads");
    //use the physical path 
    Editor1.SetSecurityImageGalleryPath("c:\inetpub\wwwroot\uploads");


    VB Example:

    //use the app-based path 

    Editor1.Setting("security:ImageGalleryPath")= "~/uploads"
    //use the absolute path 
    Editor1.Setting("security:ImageGalleryPath")= "/uploads"
    //use the physical path 
    Editor1.Setting("security:ImageGalleryPath")= "c:\inetpub\wwwroot\uploads" 
    or
    //use the app-based path 

    Editor1.SetSecurityImageGalleryPath("~/uploads")
    //use the absolute path 
    Editor1.SetSecurityImageGalleryPath("/uploads")
    //use the physical path 
    Editor1.SetSecurityImageGalleryPath("c:\inetpub\wwwroot\uploads") 

    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

  •  06-26-2007, 4:29 AM 31077 in reply to 30963

    Re: Image Folder Other than under App Folder?

    Adam,

    I can get it to work if I have images in a folder under the app itself (e.g. http://localhost/application/uploads), but not when folder is outside of the application's virtual folder....

    So, my application is:

    http://localhost/application

    My  images folder is:

    http://localhost/imagelib (virtual folder)

    I have tried using "/ImageLib" (gives me InvalidOperationException: Failed to map the path '/ImageLib/') , I have tried using "E:\InetPub\wwwroot\ImageLib" which is the physical path (gives me InvalidOperationException: Failed to map the path '/'), but they both error.

    Any ideas on what the problem is?

    Cheers,
    Carin

  •  06-26-2007, 10:21 PM 31110 in reply to 31077

    Re: Image Folder Other than under App Folder?

    Carin,
     
    It is strange. I just did a test. It works great here.
     
    Which version of Cute Editor are you using?
     
    Can you download the latest build and try again?
     
     

    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

  •  06-27-2007, 4:59 AM 31122 in reply to 31110

    Re: Image Folder Other than under App Folder?

    Adam,

    Well, I worked out what it is.... I was running VS2005 and that uses a custom web server thingie, so IIS is not involved. So, running via debugging in VS2005 starts up the app running in that custom server, with the Imagefolder as an IIS virtual folder, which I assume the custom web server knows nothing about and so the Image path errors.

    BUT, if I set up the app (and the image folder of course) as an IIS virtual folder and run it separately (not via VS) the image path works fine! :)

    Cheers,
    Carin

View as RSS news feed in XML