Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Aiheen aloitti: t3ngu - lokakuu 27, 2009, 03:21:44 IP

Otsikko: Hide redirect count
Kirjoitti: t3ngu - lokakuu 27, 2009, 03:21:44 IP
Hello,

I made one of the boards "redirect to a web address", but is there a way to hide the redirect count (how many times it was clicked)?
Otsikko: Re: Hide redirect count
Kirjoitti: greyknight17 - lokakuu 27, 2009, 05:04:36 IP
Don't know of an easy way to do this. The redirect count is linked to the post count as well. Removing one will most likely remove the post count as well.
Otsikko: Re: Hide redirect count
Kirjoitti: LOVELORD - lokakuu 27, 2009, 05:36:31 IP
Do you use redirect boards mod?

There is a optin when you cna chose that in dont cont clicks.
Otsikko: Re: Hide redirect count
Kirjoitti: H - lokakuu 27, 2009, 06:00:39 IP
If you let us know which theme you're using we can give you the edits needed to remove the counter :)

Lainaus käyttäjältä: LOVELORD - lokakuu 27, 2009, 05:36:31 IP
Do you use redirect boards mod?

This is in the 2.0 board, where it is a feature and not a mod :)
Otsikko: Re: Hide redirect count
Kirjoitti: t3ngu - lokakuu 27, 2009, 08:42:08 IP
Lainaus käyttäjältä: H - lokakuu 27, 2009, 06:00:39 IP
If you let us know which theme you're using we can give you the edits needed to remove the counter :)

Lainaus käyttäjältä: LOVELORD - lokakuu 27, 2009, 05:36:31 IP
Do you use redirect boards mod?

This is in the 2.0 board, where it is a feature and not a mod :)

I'm using the default theme that comes with 2.0.
Otsikko: Re: Hide redirect count
Kirjoitti: H - lokakuu 28, 2009, 07:38:38 IP
Try opening Themes / default / boardindex.template.php

Find:

', $board['is_redirect'] ? $txt['redirects'] : $txt['posts'], '

And delete. Please take a backup of the file as this is untested :)
Otsikko: Re: Hide redirect count
Kirjoitti: t3ngu - lokakuu 28, 2009, 07:49:37 IP
It still shows the redirect count, but it just changed the text from "x removed" to "x". It also removed the text for REPLIES in other boards, so I'm assuming they both use the same counter.
Otsikko: Re: Hide redirect count
Kirjoitti: Arantor - marraskuu 24, 2009, 06:00:13 AP
They do use the same counter internally.

Koodi (find) [Valitse]
', comma_format($board['posts']), ' ', $board['is_redirect'] ? $txt['redirects'] : $txt['posts'], '

Koodi (replace) [Valitse]
', ($board['is_redirect'] ? '' : comma_format($board['posts']) . ' ' . $txt['posts']), '