Try our conversational search powered by Generative AI!

Adding migrated VPP upload directory to IIS7-powered site



I am trying to add an upload directory to a migrated site from EPi 4.62b to CMS R2. I have since then also upgraded the site to R2 SP1. I am runnning a Windows Server 2008 site with IIS 7.

My steps:

1. Added the (migrated) /upload directory to the VPP directory E:\www-upload - and also made sure that the migrated database is used on the web site.

2. Added the following in web.config, inside the /VirtualPath/providers xpath:
< add virtualPath="~/upload/" physicalPath="E:\www-upload\upload"
showInFileManager="true" virtualName="upload" bypassAccessCheck="false"
name="Siteupload" type="EPiServer.Web.Hosting.VirtualPathVersioningProvider,EPiServer" />

3. Set the correct rights for account NETWORK SERVICE to modify files on the physical upload directory.

This approach works fine on my local IIS 5.1 installation, but on IIS7 the images and documents inside upload can not be shown. If I try to browse the EPiServer file manager inside edit mode of the IIS7 site, I can read the full structure of the upload directory, so I know they are there and rendered properly by the database, but I cannot view them there (either).

Also, I have no trouble adding images or documents that can be viewed to the standard VPP folders "Global" or "Documents", it is within the VPP folder "upload" something goes awry.

Is there anyone that has some pointers on how to go forward with this?


Apr 01, 2009 16:03
Have you added a <location>-element for "upload" just as there is for the other folders like "Global" ?
Apr 01, 2009 16:21

It's the location element only needed if one are running IIS6?



Apr 02, 2009 7:24

You need the following location element for IIS 7:

<location path="upload">
         <add name="webresources" path="WebResource.axd" verb="GET"
                  type="System.Web.Handlers.AssemblyResourceLoader" />
         <add name="wildcard" path="*" verb="*"
            type="EPiServer.Web.StaticFileHandler, EPiServer" />

Apr 02, 2009 8:35

It was indeed the case of me forgetting the location element. It works fine now since I added it. Thanks to all for your input.

Apr 02, 2009 9:12
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.