Announcement

Collapse
No announcement yet.

get previous visited url in tpl file

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • get previous visited url in tpl file

    how to get get previous visited url in tpl file.

  • #2

    Add the following into the view for your template:
    Code:
     data:function()
    {
     var data = Dep.prototype.data.call(this);
    [B] data.previousUrl = document.referrer;[/B]
     return data;
    }
    Than you should be able to get the previous url with {{previousUrl}}

    Comment

    Working...
    X