We have a project where we want the pdf’s to appear to appear as if they are within the folder of the page for SEO value, e.g. www.umbraco.org/about-us/this-is-a-pdf.pdf
Sounds like a job for either URL rewriting, or a custom Umbraco 404 Handler.
For URL Rrewriting though, I'd imagin you'd have to get .NET to handle all files. Not sure on the actual rewrite rule, but the documentation for the built in rewriter is here:
I was beginning to think this might be the case. I think we might develop this as a package as it seems it would be useful. It almost could function like umbracoInternalRedirectId but use a media picker instead of a content picker.
Maybe add a property to the "File" media type of "myUrlAlias" or something (allow comma seperated?) then create a 404 handler which looks up the files based on that property? Job done! =)
Could make for an interesting package. Give it a go, what's the worse that could happen? =)
Media Document URLs
Hi,
We have a project where we want the pdf’s to appear to appear as if they are within the folder of the page for SEO value, e.g. www.umbraco.org/about-us/this-is-a-pdf.pdf
Does anyone know how this could be done?
Thanks,
Jeavon
Hi Jeavon,
Sounds like a job for either URL rewriting, or a custom Umbraco 404 Handler.
For URL Rrewriting though, I'd imagin you'd have to get .NET to handle all files. Not sure on the actual rewrite rule, but the documentation for the built in rewriter is here:
http://www.urlrewriting.net/160/en/documentation.html
And you can find a little info on 404 handlers here:
http://our.umbraco.org/wiki/how-tos/how-to-implement-your-own-404-handler
Matt
Hi Matt,
I was beginning to think this might be the case. I think we might develop this as a package as it seems it would be useful. It almost could function like umbracoInternalRedirectId but use a media picker instead of a content picker.
Thanks,
Jeavon
Yea,
Maybe add a property to the "File" media type of "myUrlAlias" or something (allow comma seperated?) then create a 404 handler which looks up the files based on that property? Job done! =)
Could make for an interesting package. Give it a go, what's the worse that could happen? =)
Matt
is working on a reply...