Copied to clipboard

Flag this post as spam?

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


  • North Krimsly 59 posts 80 karma points
    Jul 27, 2010 @ 19:34
    North Krimsly
    0

    clean URLs, friendly URLs on shared hosting, remove ".aspx"

    Greetings all,

    I'd like to use clean URLs with Umbraco on my shared hosting account at SoftSys (removing ".aspx" from URLs).  I tried modifying the web.config for Umbraco as follows:

     <add key="umbracoUseDirectoryUrls" value="true" />

    And then republishing the entire site.  However, this didn't have any effect. SoftSys says they support clean URLs, but that I need to create an additional IIS rule in web.config so it will handle clean URLs. I would appreciate if anyone has guidance or pointers on if this sounds correct, and if so what rule do I need to add to web.config?

    Thanks,

    -NorthK

  • Stefan Kip 1614 posts 4131 karma points c-trib
    Jul 27, 2010 @ 20:17
    Stefan Kip
    0

    When you republished the entire site and look on one of you content nodes, what does "Link to document" on the Properties tab say?

  • Chad Rosenthal 272 posts 474 karma points
    Jul 27, 2010 @ 20:19
    Chad Rosenthal
    0

    In IIS 6, you will need access to the server. I had to go into the  Properties, and then into the Home Directory tab. Then click 'Configuration'.  You will need to add a 'wildcard application map' to the aspnet_isapi.dll (often found here C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll).

    From my experience, this is something that you can not do from within a web.config. Also from my experience, you will need to call up the hosting company and ask them to do this. Strangely, you might have to step them through the process.

    If you're trying to get it to work on IIS7, then the steps will be different. 

  • North Krimsly 59 posts 80 karma points
    Jul 27, 2010 @ 21:25
    North Krimsly
    0

    kipusoep,

    When I look at the "Link to document", it has the correct path (such as "/home" not "/home.aspx"). However clicking on that link results in a 404 page while navigating to /home.aspx loads the page properly.

    Chad,

    Looking at the IIS docs, it looks like I could add a rewrite rule section to web.config, something like as follows.  I'm curious if you'd tried this and it didn't work?  I'd like to try it but I'm having trouble finding the magic code for the specific rewrite rule I want (remove .aspx):

    <rewrite>
      <rules>
        <rule name="Rewrite to article.aspx">
          REWRITE RULE GOES HERE
        </rule>
      </rules>
    </rewrite>

    Any other ideas guys?

    Thanks,

    -NorthK

  • Stefan Kip 1614 posts 4131 karma points c-trib
    Jul 27, 2010 @ 21:33
    Stefan Kip
    0

    @North

    You do not have to add rewriting rules. Umbraco takes care of that.

    You have to let IIS dispatch the requests to ASP.NET. How you can do that explains Chad (or maybe the hosting company?)

  • Jeff Grine 149 posts 189 karma points
    Jul 27, 2010 @ 22:19
    Jeff Grine
    0

    If you're on SoftSys you should be running IIS 7 and shouldn't actually have to do anything, except for the appSetting key you've already changed. Sorry that's not much help. Does the page work if you hit /home.aspx instead of /home?

  • Paul Blair 466 posts 731 karma points
    Jul 27, 2010 @ 22:52
    Paul Blair
    0

    What version of Umbraco. If you're at 4.0.x then you will need to get the web.config for integrated pipelines.

    If you're using 4.5 then you don't need to do anything.

    Then at Softsys make sure you are using intgrated pipelines (in the extension tab for your website).

    Use 4.0 integrated if you are using Umbraco 4.5, otherwise 2.0 integrated.

    No other changes to IIS are required

  • North Krimsly 59 posts 80 karma points
    Jul 28, 2010 @ 17:49
    North Krimsly
    0

    All,

    Thanks for taking the time to reply.  It turns out that I needed to purchase a dedicated app pool at Softsys, in order for them to make the necessary changes to the IIS settings for my account.  Once I did that and they made the changes, the Umbraco "add key" rewriting rule worked as it should.

    Thanks again,

    -NorthK

  • Connie DeCinko 931 posts 1160 karma points
    Jul 29, 2010 @ 20:30
    Connie DeCinko
    0

    If I manually remove the .aspx from my URL, the page displays just fine.  However, links shown in the Properties tab and links generated by NiceURL in XSLT macros still have the .aspx.  I'm running v.4.5.  What do I need to do?

     

  • Paul Blair 466 posts 731 karma points
    Jul 29, 2010 @ 22:38
    Paul Blair
    0

    Connie, have you re-published the entire site?

  • Connie DeCinko 931 posts 1160 karma points
    Jul 29, 2010 @ 23:15
    Connie DeCinko
    0

    It works now.  I was looking at the value in my backup web.config instead of the live copy.

  • AntonioMX 58 posts 57 karma points
    Nov 20, 2010 @ 17:45
    AntonioMX
    0

    Sorry for the double post, but I don't really know where to put this. I have removed the aspx from my URLs with the help of this and setting the umbracoUseDirectoryUrls key  to true, will this affect negatively my search engine rankings or number of indexed URLs?

Please Sign in or register to post replies

Write your reply to:

Draft