How do you create a shortlink/alias to be directed to a PDF

Leslie Mueller asked on January 16, 2019 15:19

I know how to create an alias to a specific page, but I can't seem to figure out how to create an alias to be redirected to a pdf on our website.

Recent Answers


Tomáš Loun answered on January 16, 2019 17:31

Hi Leslie, where is the PDF placed? You have it inserted in content tree as a file, you can simply go to Properies ~ URLs and click Add new alias. Then you type the alias to Path or pattern. Take care, the page will not have pdf extension. When you type /testpdf, the address could be http://localhost/testpdf.aspx

If you do not have your PDF in content tree, simply create new page and go to Properities ~ Navigation and enter URL of the pdf to Menu actions / URL redirection. You can set alias to this page then if needed.

Regards, Tom

0 votesVote for this answer Mark as a Correct answer

Leslie Mueller answered on January 16, 2019 17:34

the PDF is placed in the media library, it isn't part of the content tree.

0 votesVote for this answer Mark as a Correct answer

Tomáš Loun answered on January 16, 2019 17:47

ok, you will find there Direct path and Permanent link - these are URLs of the PDF. Use one of them and put it to Properties - navigation in newly created page as I have described earlier.

0 votesVote for this answer Mark as a Correct answer

Eric Dugre answered on January 16, 2019 19:50

The solution that Tomáš suggested regarding the URL redirection field will unfortunately not work. This setting only changes the URL that appears in navigation web parts but if you attempt to access the redirection URL directly, you will most likely get a 404 response.

If you want to create a "custom URL" for a media file, using IIS redirection is probably the most efficient approach: https://docs.microsoft.com/en-us/iis/configuration/system.webserver/httpredirect/. There are also some custom modules that could help you implement these redirects in the Kentico UI instead:

  • https://devnet.kentico.com/marketplace/modules/custom-301-redirect-module
  • https://devnet.kentico.com/marketplace/modules/custom-redirects-module
0 votesVote for this answer Mark as a Correct answer

Leslie Mueller answered on January 16, 2019 19:54

thanks everyone. I did share your comments with our web coordinator and she has been able to use your suggestions to get it to work.

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.