Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Andrew Tregonning 19 posts 41 karma points
    Oct 28, 2010 @ 00:52
    Andrew Tregonning
    0

    Default document in IIS ignored

    Hi

    We're in the process of developing our umbraco site, and are not yet ready for the public to see it, so I want to display a "coming soon" splash page when people visit http://mysite.com/ and be able to access the real site at http://mysite.com/Default.aspx for development.

    I've created my splash page, "Default.html", in the root of the website and have added it to the list of umbracoReservedUrls in the web.config. When I browse to http://mysite.com/Default.html the page is displayed as expected.

    In IIS, I've set "Default.html" as the default document, but when I browse to http://mysite.com/, the front page of my umbraco site is displayed instead of my splash page.

    I've had this working previously in older versions. Has it changed in version 4.5, or am I missing something? Is there a better way to achieve this?

    Cheers,
    Andrew

     

  • Paul Blair 466 posts 731 karma points
    Oct 28, 2010 @ 02:22
    Paul Blair
    0

    Have you got integrated pipelines turned on in IIS?

    Failing that, you could try putting defaultPage="default.html" into your /config/urlrewriting.config file. e.g.

    <urlrewritingnet defaultPage="default.html" xmlns="http://www.urlrewriting.net/schemas/config/2006/07">

     

  • Andrew Tregonning 19 posts 41 karma points
    Oct 28, 2010 @ 02:53
    Andrew Tregonning
    0

    Hi Paul

    Thanks for your reply. The urlrewriting.config suggestion looks like the winner, however it's not quite right.

    When I go to http://mysite.com/ I'm redirected to http://mysite.com/default.html, and when I go to http://mysite.com/default.aspx I get the front page of my umbraco site as expected - that's all good.

    However, when I try to navigate to a page in side my site, such as http://mysite.com/contact, it is rewritten to http://piriedev/contact/default.html and I get a 404. Is there another tweak I can put into the urlrewriting.config file to overcome this?

    Cheers,
    Andrew

     

  • Paul Blair 466 posts 731 karma points
    Oct 28, 2010 @ 03:21
    Paul Blair
    0

    Hi,

    It looks like you're at the same stage I got to. The only way I could get it to work was to turn integrated pipelines and directory-less URL's of during development and then turn them back on when the site goes Live. It feels like a bit of a hack doesn't it?

  • Andrew Tregonning 19 posts 41 karma points
    Oct 28, 2010 @ 05:15
    Andrew Tregonning
    0

    Hi Paul

    Yes, it is pretty hacky, isn't it.

    Thanks for the tip though - I've now turned off umbracoUseDirectoryUrls and got it working.Now I'll have to remember to turn it back on before going live!

    Cheers,
    Andrew

     

  • Harry Gordon 15 posts 92 karma points c-trib
    Jun 16, 2013 @ 02:05
    Harry Gordon
    0

    Hi guys,

    I tried the tweak to the urlrewriting.config but it broke my Base methods.

    Anyone come across an ideal solution?

    Thanks,

    H

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies