Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Back to Discussions

sjeepssjeeps
edited July 2007 in Vanilla 1.0 Help
wouldn't it be much better when users click on "Back to Discussions" link, it will take them back to the page where they were at instead of going back to the index.php?
I looked into comments_foot.php and the the code looks like this:

<a href="'.GetUrl($this->Context->Configuration, 'index.php').'" class="left">'.$this->Context->GetDefinition('BackToDiscussions').'</a>

So my question is how to change that line to take the users back to let's say /discussions/2/or discussions/3/ etc.?

Comments

  • OK, I've changed the line to this:

    <a href="javascript:history.back()" class="left">'.$this->Context->GetDefinition('BackToDiscussions').'</a>

    It worked but I was just not sure if this the way to do it.
  • What if they went to page 3 and came from page 2? Then "Back to Discussions" wouldn't bring them back to the discussions, only one page back...
This discussion has been closed.