How to redirect unpublish news item to the News List

David Pearson asked on November 3, 2016 13:48

I have a news section on the site. Some of the news are not publish anymore. How do I 301 redirect an unpublished or missing news item to the parent new list page?

Thanks David

Recent Answers


Trevor Fayas answered on November 3, 2016 15:47

I know if you delete a page, it gives you an option to set a new pages as it's location. I believe you have a couple options:

  1. (less desirable) Delete the page and set the new page as it's replacement, this sets up a URL alias i believe on that page you specify.
  2. Leave the 'old' page in a published state, then in Navigation -> Set Menu Actions to Url Redirect and put in the page you wish it to go to (this will redirect people, but the page must be published, you may want to add some other field to say "don't show this page" on news listings)
  3. Move the news story to some other location (like an archive folder) so the NodeAliasPath changes, remove the Url Aliases created from the move, then add the old "Url" path to the page you wish people to go to (parent news page)

Hope this helps!

0 votesVote for this answer Mark as a Correct answer

David Pearson answered on November 3, 2016 19:01

If the news story does not exist how do I direct to the News List instead of a page not found. I was thinking of looking at the url for the "News" to be in the path.

Is there a way for Kentico to redirect to the parent page?

0 votesVote for this answer Mark as a Correct answer

Brenden Kehren answered on November 3, 2016 22:44

Did the answer(s) I provided back in Sept not work?

http://devnet.kentico.com/questions/redirect-an-archived-page

2 votesVote for this answer Mark as a Correct answer

David Pearson answered on November 4, 2016 14:01

Hi Brenden, This question is a different angle. This question deals with old articles (300+ articles) that are not publish anymore and articles that were never in kentico...

After some thinking, I am now using the show non-published pages on the website in the Settings -> Content to avoid the 404 for articles that still exist on the site and leave the 404 for articles that never exist.

0 votesVote for this answer Mark as a Correct answer

Brenden Kehren answered on November 4, 2016 19:41

So for articles never in Kentico, just create an alias on the root /articles page for that old URL. For the non-published, you can do the same but if they are in Kentico, use the same approach I mentioned in the previous reply.

1 votesVote for this answer Mark as a Correct answer

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