TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

May 18, 2024, 09:47:53 PM

Login with username, password and session length
Members
  • Total Members: 3,886
  • Latest: Grendor
Stats
  • Total Posts: 195,189
  • Total Topics: 21,220
  • Online today: 112
  • Online ever: 3,540 (September 03, 2022, 01:38:54 AM)
Users Online
  • Users: 0
  • Guests: 40
  • Total: 40

"Mark All Messagea As Read" redirect

Started by en_shua, August 02, 2009, 06:13:50 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

en_shua

On my forum, when we click on "Mark All Messages As Read, it takes up back to the forum index (index.php?action=forum).  Does anyone know where or how I can change it so that it redirects to "index.php" instead?

Thanks.

ZarPrime

You could try the fix in this post by Bloc ...
http://www.tinyportal.net/index.php/topic,23213.msg188221.html#msg188221

Use the code at the bottom for the /Sources/Subs.php

That will also redirect you back to the Front Page on login and logout.

ZarPrime

FragaCampos

Curious, i wish my forum did exactly that  ::)
I mean, when i Mark All Messagea As Read it redirects me to the frontpage, but i wish it redirects to the forum's index.
Any clue on how to do this?

IchBin

Did you try the fix in the link posted by Zarprime?

FragaCampos

I may have understood wrong, but the fix that exists on that topic does exactly the opposite of what i would like to see.
The redirections are all ok in my forum, they all go to TP frontpage, but i would like to avoid that only if i mark all messages as read, i.e., when i do that, i want to go to SFM index (forum), and not TP frontpage.
Hope i made some sense :P

ZarPrime

FragaCampos,

I wish you has started a new topic on your issue instead of using someone else's topic because your issue is a different issue.  However, since you didn't, I'll deal with it.

So, am I to understand that you have already made the change to the Subs.php that Bloc mentioned in his post?  If you are redirecting to the FrontPage on login and logout, then this would seem to be the case.

It's likely that this is the reason why the redirect is happening as it is when you mark messages read.  At this time, I don't have any way to test this.  If you would like to test to see what happens when you revert the code that Bloc mentioned to the way it comes out of the box, I would be interested in knowing what happens.  However, I doubt that it will work both ways for you.  It's probably either going to redirect either to the Frontpage or to the Forum for both the Login/logout redirect and the mark as read issue.  I don't know of a way to make it redirect differently depending on what your action is.

ZarPrime

FragaCampos

Thanks for answering ZarPrime.
I just "took" this topic because it's the same issue, only the reverse  :P I did it to avoid opening another topic. It was with the best of intentions.

Unfortunately, what you say is true, i.e., it's either 80 or 8 on this. If i change the subs.php file again, it redirects everything to the SMF's index, including login/logout etc.
The solution would be, as you mentioned, to change redirection depending on the action.

Hope someone can help on this, cause i surely can´t  ::)

ZarPrime

#7
FragaCampos,

I just did a little bit of checking on this.  I have a Forum setup with TP 1.0 beta 1, that I had earlier edited with Bloc's fix, and it correctly redirects to the Frontpage on login and logout as it should.  The SMF version on that site is 1.1.7, but that should make no difference between that version and 1.1.10.  I tried to mark a couple of topics unread, and when I did so, the redirect went to the index of the board that those messages were in, which I believe is what you wanted to happen.

There is no particular reason that I can think of why it wouldn't happen this way on your site as well even though you aren't using the same version of TP.

ZarPrime

IchBin

Did you try marking a board as read Zarprime? That is different than marking a topic read.

ZarPrime

#9
Ah, no I didn't try that.  Let me try that and I'll report back.

ZP

Edit:  Hmmm, marking a board as read that had a couple of unread topics in it just kept me on the same board index but marked all topics as read.  It didn't redirect me to either the Frontpage or to the Forum main index.  I think that's what he was trying to do but I'm not sure.  I guess maybe I need to get a clarification from FragaCampos and perhaps even try editing the subs.php on my TP beta 4 test site.

FragaCampos

No, ZarPrime, you got it right on the first one. In my case, i believe i didnÃ,´t do anything besides Bloc's fix.
What i really wanted is when in the forum's index, you click "Mark Messages as read" (not "topics" or "boards") and are redirected to forum's index, not TP's frontpage..

bloc

Thats how it should perform, but there might be a bug there.

ZarPrime

Let me see if I can answer this once and for all.  I have done a few more tests.

It seems that if you have done Bloc's fix, to redirect to the FrontPage on login/logout, and you are on the Forum main index, the action "mark all messages as read" at the bottom of the main Forum index will redirect you to the FrontPage.

On the other hand, if you have not made The edit Bloc mentioned, you will not be redirected to the FrontPage but will stay on the Forum index instead.

ZarPrime

FragaCampos

Thank you guys for your help but i solved the problem in a easier way... i installed the most recent Tp version and now everything is ok.

Thanks for your patience.

ZarPrime

Since the original poster has not responded for awhile to the original fix, I must assume that this topic is solved for them as well, and will mark the topic accordingly.

ZarPrime