Hmm. In the site I'm currently working on umbracoUseDirectoryUrls was already set to true but I'm still seeing the .aspx instances. The site is using Umbraco 7.2.6. Any ideas?
You can use my .aspx removal redirect for UrlRewriting.net:
<!-- SEO | Trim .aspx for directory URLs -->
<!-- Note: using UrlRewriting.Net because IIS UrlRewriting doesn't like rules with .aspx in it -->
<add name="SEO | Trim .aspx for directory URLs"
redirect="Application"
redirectMode="Permanent"
virtualUrl="^/(?![0-9]+.aspx)(?!umbraco/)([^\?]*?).aspx$"
rewriteUrlParameter="ExcludeFromClientQueryString"
destinationUrl="/$1"
ignoreCase="true" />
Hey I'm having the same issue, just trying to get rid of the .aspx because my seo tools are showing duplicate content. I'm running Umbraco 7.5, where would I add this in the web.config?
Can references to .aspx or index be defeated to avoid duplicate content hits in SEO?
Case in Point:
When creating a page in umbraco it creates two paths
markets-products/building-products/
and
markets-products/building-products.aspx
Many SEO tools pick this up as duplicate content as do search engines.
Is there any way to force only one instance?
Hi Christopher,
You can remove the .aspx extension by modify the web.config file. In the web.config, search for umbracoUseDirectoryUrls.
If you set it to true, then it strips .aspx from URLs on the front-end w
This setting is only important to older IIS configurations where extension-less URLs weren't supported very well. See https://our.umbraco.org/documentation/reference/config/webconfig/
If you want to avoid the trailing slash in the end of you Urls, then you need to change the to false
You will find the setting in the umbracoSettings.config which is located in config folder /Config/umbracoSettings.config
Hope this helps,
/Dennis
Hmm. In the site I'm currently working on umbracoUseDirectoryUrls was already set to true but I'm still seeing the .aspx instances. The site is using Umbraco 7.2.6. Any ideas?
You can use my .aspx removal redirect for UrlRewriting.net:
Hey I'm having the same issue, just trying to get rid of the .aspx because my seo tools are showing duplicate content. I'm running Umbraco 7.5, where would I add this in the web.config?
Excellent. Thank you for sharing.
is working on a reply...