Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to get Umbraco to handle requests for non .aspx files (IIS integrated pipeline mode)?
    primarykey
    data
    text
    <p>I'm trying to get the <a href="http://our.umbraco.org/projects/developer-tools/301-url-tracker" rel="nofollow">301 URL Tracker package</a> for Umbraco to work to my likings.</p> <p>My goal is to be able to map the old URLs (from another CMS) to the new Umbraco URLs. In my specific situation, the old site is PHP based and therefore use the .php file extension (http://example.net/test.php -> <a href="http://example.net/test/" rel="nofollow">http://example.net/test/</a>) - but it could be any non .aspx extension (asp, png and so on). The problem is that Umbraco is not handling request for .php files. It works perfectly for .aspx and directories (extensionless URLs).</p> <p>I have tried various things for getting this to work. Before I go any further, I should note that the Application Pool is in <strong>integrated mode</strong> and .NET 4.0.</p> <p>I kind of got it to work by defining a custom error in the web.config:</p> <pre><code>&lt;customErrors defaultRedirect="not-exists.aspx" /&gt; </code></pre> <p>This triggers the handlers defined in NotFoundHandlers in the Umbraco config file 404handlers.config. But has the side effect of returning a 302 Found header, before the 301 URL Tracker kicks in and handles the 301 redirect. And this is just a big SEO "no no".</p> <p>I then tried to explicitly create a HTTP handler module for .php files. I successfully got the System.Web.UI.PageHandlerFactory module to handle the request for the .php file. But this does not invoke any of the NotFoundHandlers in Umbraco.</p> <p>As I understand the integrated pipeline in IIS 7, all the modules registered should try to handle the request (http://stackoverflow.com/questions/3765317/how-to-catch-non-aspx-files-with-a-http-module). But perhaps somebody can enlighten me on this subject?</p> <p>Others are also experiencing the difficulties in getting this configuration to work: <a href="http://our.umbraco.org/projects/developer-tools/301-moved-permanently/feedback/7271-when-the-old-pages-are-not-from-umbraco" rel="nofollow">http://our.umbraco.org/projects/developer-tools/301-moved-permanently/feedback/7271-when-the-old-pages-are-not-from-umbraco</a></p> <p>What am I missing in getting Umbraco to handle request for non .aspx files in integrated pipeline mode?</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload