How do I recognize previous page in kentico macro ?

Ameya Kulkarni asked on August 17, 2017 17:17

I want to check a condition in my kentico macro which requires recognizing the previous page from which I navigated to the current page. Is there away to do that ?

Recent Answers


Peter Mogilnitski answered on August 17, 2017 19:59 (last edited on March 24, 2018 12:15)

You are talking about page referrer i.e. {% CurrentBrowser.UrlReferrer |(user)zbynekh|(hash)2685851df7b650cc7d1f79be49e7af4d7c9e1b0e33aad892e9904da044db34e5%}

so for example: {% if (CurrentBrowser.UrlReferrer.Contains("ABC")) { do something here... }|(user)zbynekh|(hash)56baa5d4ef3514f5a1a0c45c78622669ab53af6421a3491924573c98dd736029%}

1 votesVote for this answer Mark as a Correct answer

Brenden Kehren answered on August 20, 2017 15:53

The UrlReferrer is only populated when the visitor comes from another site. In my experience, will not keep track the pages when the visitor is aleady on the site.

1 votesVote for this answer Mark as a Correct answer

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