Copied to clipboard

Flag this post as spam?

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


  • Jon 17 posts 37 karma points
    Oct 06, 2009 @ 19:05
    Jon
    0

    Adding Non Umbraco Pages to Site

    I am using umbraco 4 and so far things have been great.  I do have an old project (web application) that was designed in asp.net, and was wondering if there is a way to just add the aspx pages to the umbraco site and use them as they are without converting them to be used in umbraco. 

    I have tried adding the aspx pages to the umbraco directory and when i try to navigate to the page i get an umbraco page not found error.  Any suggestions?

    Thanks,

    Jon Clifford

  • Rich Green 2246 posts 4008 karma points
    Oct 06, 2009 @ 19:17
    Rich Green
    0

    You need to add the files to a folder other than the 'Umbraco' folder and add the new  folder name as below in the web.config file

    <add key="umbracoReservedPaths" value="/umbraco,/install/,/YOUR_FOLDER/"/>

    or if you want to add them as individual files you can do so by adding them to the umbracoReservedUrls:

    <add key="umbracoReservedUrls" value="/config/splashes/booting.aspx,/install/default.aspx,/config/splashes/noNodes.aspx" />

    Rich

     

     

  • Jon 17 posts 37 karma points
    Oct 06, 2009 @ 19:45
    Jon
    0

    Thanks for your reply rich, so if i put them into a folder called /webapplication/  and add 2 files in called index1.aspx and index2.aspx can i navigate to the pages by doing www.sitename.com/index1.aspx or do i have to add the webapplication folder before it like www.sitename.com/webapplication/index1.aspx.  i would prefer to have it work like the first url.

    Jon

  • Rich Green 2246 posts 4008 karma points
    Oct 07, 2009 @ 09:58
    Rich Green
    0

    Hi Jon,

    You can, however I believe you'll need something 'unique' in your URL to let the urlrewriting know to pass this file directly.

    You would have to add a URL Rewriting rule to the 'config/URLrewriting.config' file.

    Something like:

    <add name="AnyUniqueNameHere" virtualUrl="^~/web_(.*).aspx"
        rewriteUrlParameter="ExcludeFromClientQueryString"
        destinationUrl="~/WebApplication/$1.aspx"
        ignoreCase="true" />

    In this case www.sitename.com/web_index1.aspx would map to www.sitename.com/webapplication/index1.aspx

    Also you would need to ensure that no Umbraco created files match so I doubt it's 'recommended' practise, for example a page in Umbraco named web_index2'  would cause an error as as it would map to www.sitename.com/webapplication/index2.aspx

    Hope this helps.

    Rich

  • Luke Johnson 61 posts 80 karma points
    Aug 17, 2011 @ 20:01
    Luke Johnson
    0

    I got the path to work by adding the <add key="umbracoReservedPaths" value="/umbraco,/install/,/YOUR_FOLDER/"/> to web.config. However, this seems like quite a pain-staking process to add a line to the web.config file every time a new folder is manually added to the root. Is there any way to automate this process? Is there a way to cause Umbraco to update its web.config when a new folder is added to its public root?

    Thanks,

    Luke

  • jaygreasley 416 posts 403 karma points
    Aug 18, 2011 @ 10:30
    jaygreasley
    0

    hey

    If it is indiviual pages you are adding then I'd be tempted to have one top level folder that is excluded from Umbraco and have all the pages under that.

    jay

  • PolishPaul 11 posts 31 karma points
    Sep 06, 2011 @ 02:29
    PolishPaul
    0

    I'm not sure if i'm trying to do the same thing as the original poster but i tried the solution and it isn't working as i expected.

    What I'm trying to do is to have subfolders i can create without umbraco intercepting them. For example i want domain.com/whatever/ to serve the contents of that folder. When i addthe server is looking at:

    \wwwroot\umbraco\apps\
    instead of
    \wwwroot\apps\

    How can i serve pages from that physical folder?

    I realized that the above is happening because umbraco is installed in webroot\umbraco folder. I just tried it on my own test server where umbraco is installed in the website root. However I'm still unable to get this to work. I think its best i start a new thread...

Please Sign in or register to post replies

Write your reply to:

Draft