Portal Engine Questions on portal engine and web parts.
Version 6.x > Portal Engine > Extensions and trailing slashes. View modes: 
User avatar
Member
Member
trint.ladd@altn.com - 1/24/2012 4:59:49 PM
   
Extensions and trailing slashes.
Our previous website used URLs in these forms:
(pages) http://OurSite.com/SomePath/SomePage/
and
(files) http://OurSite.com/SomePath/SomeFile.pdf

So, using Kentico 6.0, we need to have extensionless pages with trailing slashes. I have done the IIS6 Custom error mod (here: http://devnet.kentico.com/docs/devguide/index.html?configuration_of_extensionless_urls.htm) to get the extensionless pages. Then, I set "Use URLs with trailing slash" to "Always use URLs with trailing slash" (http://devnet.kentico.com/docs/contexthelp/index.html?settings_urls.htm).

This works great for pages ("/SomePage/") but terrible for files ("/SomeFile.pdf/").

Trolling the forums, I found this (http://devnet.kentico.com/Forums.aspx?forumid=47&threadid=15087) which recommends a web.config entry "CMSUseTrailingSlashOnlyForExtensionLess". This didn't work for me.

Can someone help me figure out how to maintain my extensionless pages with trailing slashes and get files with correct extensions and no trailing slash??

Thanks!

User avatar
Kentico Support
Kentico Support
kentico_jurajo - 1/25/2012 7:24:48 AM
   
RE:Extensions and trailing slashes.
Hi,

Could you please describe us your URL and SEO settings from the Site Manager -> Settings for given site? I know this is working fine for other customers so I think it will be some small setting missing somewhere.

Thank you.

Best regards,
Juraj Ondrus

User avatar
Member
Member
trint.ladd@altn.com - 1/26/2012 9:03:52 AM
   
RE:Extensions and trailing slashes.
Certainly! After many iterations of failure, I decided to do a straight demo install of the corporate site and try it there. I'm getting the same results.

URL and SEO settings:

URL format: All blank except for a dash ("-") in "Forbidden characters replacement"

Document URLs: All blank/unchecked except for a check on "Remember original URLs when moving documents"

SEO:
Sitemap: googlesitemap.xml
301: checked
Trailing slash: Always use URLs with trailing slash
Document aliases: unchecked
Invalid case: Do not check the URLs case
And last four boxes unchecked.

User avatar
Kentico Support
Kentico Support
kentico_jurajo - 1/27/2012 3:55:22 AM
   
RE:Extensions and trailing slashes.
Hi,

I am using version 6 with latest hotfix and the same setup as you described. I have uploaded a file (using CMS.File document type) into the content tree in CMS Desk. I am able to access to file under the URLs:

~/file.pdf
~/file.pdf/
~/file/ (this is one generated by default)
~/file

It is working just fine for me. How is the link to your file created? Is it possible to see the issue somewhere online?

Best regards,
Juraj Ondrus

User avatar
Member
Member
trint.ladd@altn.com - 1/27/2012 8:47:35 AM
   
RE:Extensions and trailing slashes.
You know how it is when someone tells you their email doesn't work. They insist is broken, but when you go to their desk it works fine. You know how embarrassed the person usually is? Well that's me right now. It is working.

Honestly, I'm not comfortable with it accepting so many different link styles (SEO concerns). But at least it works.

Just to be sure though, how do I know if I have the "latest hot fix?" From Site Manager, I see I'm running v6.0.4297.

Thanks for your help.

User avatar
Certified Developer 8
Certified Developer 8
Jiveabillion - 1/27/2012 10:56:23 AM
   
RE:Extensions and trailing slashes.
Use Kentico Installation Manager to see if you have the latest hotfix. If you don't see any sites or don't see your specific site, then you need to add it. They have released many hotfixes in recent days so it is very likely that you do not have the latest hotfix, especially if you have never applied a hotfix to your site before (a new installation contains no hotfixes). You should find Kentico Installation manager in your start menu.

User avatar
Kentico Support
Kentico Support
kentico_jurajo - 1/27/2012 11:59:06 AM
   
RE:Extensions and trailing slashes.
Hi,

No problem - do not feel like that. Computers are doing sometimes strange things and sometimes I feel like they are making an idiot out of me. This happens pretty often - some caching issue or what ever (you may know what is the most popular support phrase - "have you tried turning it off and on again?" - there is something about it :-))

Regarding the hotfix number - as mentioned you can use the installation manager or just check the blog post about the hotfixes (they are released every Friday) - you can find the blog here.

Best regards,
Juraj Ondrus