We have some short URLs that seem to have stopped working... We occasionally add in directories (outside of Umbraco) and drop in a default.aspx with a redirect line of code. e.g.
Not a direct answer to your question, but there's an easier way to achieve what you're doing (if I understood you correctly)
If you add a DocType property of 'umbracoUrlAlias' you can simply add any number of URL's the content you want to display, this means your client can add/edit them too.
So within the node you want the short url to show, simply enter the url into the value of 'umbracoUrlAlias', this must be lowercase and without the .aspx extension in your case. You can have multiples separated by commas, so something like
I managed to kill our website by doing that ... (it initially looked v promising and did work)... long story...
Anything else I can try with current set up? Foreign folders with default.aspx in that have redirect code. Have tried adding all sorts to web.config but none seem to work:
Cheers, I'd tried some of the above but had no luck. For some reason, adding dir names to umbracoReservedUrls seemed to get that working. Strange because it was all working before with them listed in umbracoReservedPaths.
Trailing slash / directory URLs / umbracoReservedPaths
Hi,
We have some short URLs that seem to have stopped working... We occasionally add in directories (outside of Umbraco) and drop in a default.aspx with a redirect line of code. e.g.
www.mywebsite.com/handyURL
IIS problem? Web.config problem? Umbraco config problem?
www.mywebsite.com/handyURL/ works.
www.mywebsite.com/handyURL/default.aspx works.
www.mywebsite.com/handyURL doesn't work (anymore).
I've check IIS, the default document on directories is correctly set up. I've checked web.config, umbracoReservedPaths has the handyURL listed there.
Cheers for any help,
Hey Paul,
Not a direct answer to your question, but there's an easier way to achieve what you're doing (if I understood you correctly)
If you add a DocType property of 'umbracoUrlAlias' you can simply add any number of URL's the content you want to display, this means your client can add/edit them too.
So within the node you want the short url to show, simply enter the url into the value of 'umbracoUrlAlias', this must be lowercase and without the .aspx extension in your case. You can have multiples separated by commas, so something like
/handyurl, /anotherhandyurl, /etcetc
Rich
Hi,
I managed to kill our website by doing that ... (it initially looked v promising and did work)... long story...
Anything else I can try with current set up? Foreign folders with default.aspx in that have redirect code. Have tried adding all sorts to web.config but none seem to work:
<add key="umbracoReservedPaths" value="/dir,/dir/,~/dir,~/dir/
Same problem -> /dir doesn't work (umbraco page not found).... /dir/ works fine.
Cheers,
Hey Paul,
Strange, something must be a little off as umbracoUrlAlias has been built in for as long as I remember.
2 possible solutions
1) Try setting <addTrailingSlash>false</addTrailingSlash> to true in /config/umbracoSettings.config
2) Force all url's to have trailing slashes, have a look here http://umbraco.miketaylor.eu/2010/11/03/url-rewriting-and-seo/
Rich
Cheers, I'd tried some of the above but had no luck. For some reason, adding dir names to umbracoReservedUrls seemed to get that working. Strange because it was all working before with them listed in umbracoReservedPaths.
http://our.umbraco.org/forum/ourumb-dev-forum/bugs/8281-umbracoReservedPaths-trailing-slash
is working on a reply...