php forum
php mysql forum
php mysql smarty
 
Topic Options
#52627 - 03/19/02 05:27 AM Closed topics to bottom
Simkin Offline
Junior Member

Registered: 03/05/02
Posts: 17
Is it possible to auto move all closed topics to the bottom of the page?
Would be very nice laugh

If this function is already implemented, please ignore this suggestion.

Top
#52628 - 03/03/05 04:01 PM Re: Closed topics to bottom
Zombie Offline
Newbie

Registered: 12/07/01
Posts: 13
Has this been done ? Any News ?

Top
#52629 - 03/03/05 05:10 PM Re: Closed topics to bottom
Ian Spence Offline
Master Hacker

Registered: 01/25/03
Posts: 3765
Loc: Saint Johns, PA
this has not been done, but I'm gonna give it a shot now

Top
#52630 - 03/03/05 06:01 PM Re: Closed topics to bottom
Ian Spence Offline
Master Hacker

Registered: 01/25/03
Posts: 3765
Loc: Saint Johns, PA
In ubb_forum.cgi
FIND:

Code:
my($had_stickies, $had_polls, $had_hots, $had_moves, $had_locks) = (0, 0, 0, 0, 0);

ADD BEFORE/ABOVE:

Code:
my $bonus_html = "";
	my $is_bonus = 0;

FIND:
Code:
next unless($one && ($one =~ m/^d{6}$/));
		undef($hot_icon);

ADD AFTER:
Code:
$is_bonus = 0;

FIND:
Code:
$had_locks++;
			$closed = 'X';

ADD AFTER:
Code:
$is_bonus = 1;

FIND:
Code:
$ThisHTML .= &topic_row;

REPLACE WITH:
Code:
if($is_bonus > 0)
		{
			$bonus_html .= &topic_row;
		} else {
			$ThisHTML .= &topic_row;
		}

FIND:
Code:
$ThisHTML .= &page_bottom($had_stickies, $had_polls, $had_hots, $had_moves, $had_locks);

ADD BEFORE:
Code:
$ThisHTML .= $bonus_html;

Then clear the forum page cache

Top
#52631 - 03/03/05 08:03 PM Re: Closed topics to bottom
1QuickSI Offline
Coder

Registered: 06/10/01
Posts: 705
Loc: CT
Could this be made a selectable option (top/bottom) on a per forum basis via the ACP?
_________________________
...Steven
Hostboard.com
Running UBB v6.1.0.4
Doing what NO other UBB in the world is doing.
The first & only production UBB powered by MySQL.

Top
#52632 - 03/03/05 08:10 PM Re: Closed topics to bottom
Ian Spence Offline
Master Hacker

Registered: 01/25/03
Posts: 3765
Loc: Saint Johns, PA
already built in. if you want a closed topic to appear at the topic, sticky it

Top
#52633 - 03/03/05 09:38 PM Re: Closed topics to bottom
1QuickSI Offline
Coder

Registered: 06/10/01
Posts: 705
Loc: CT
OK I get it, I am confusing closed with sticky tipsy

I was looking for a way to make a sticky an option to be either at the top or bottom selectable by forum.

Not sure what I was thinking when I read this...
_________________________
...Steven
Hostboard.com
Running UBB v6.1.0.4
Doing what NO other UBB in the world is doing.
The first & only production UBB powered by MySQL.

Top
#52634 - 03/03/05 09:40 PM Re: Closed topics to bottom
1QuickSI Offline
Coder

Registered: 06/10/01
Posts: 705
Loc: CT
BTW if anyone is using this make sure you place an underscore between any ones missing from

$is bonus
$bonus html

They should be
$is_bonus
$bonus_html

Else you will get erros wink
_________________________
...Steven
Hostboard.com
Running UBB v6.1.0.4
Doing what NO other UBB in the world is doing.
The first & only production UBB powered by MySQL.

Top
#52635 - 03/04/05 11:45 AM Re: Closed topics to bottom
Ian Spence Offline
Master Hacker

Registered: 01/25/03
Posts: 3765
Loc: Saint Johns, PA
updated my code to add those wink tipsy

Top
#52636 - 04/19/05 04:16 PM Re: Closed topics to bottom
Zombie Offline
Newbie

Registered: 12/07/01
Posts: 13
this works great on a per-page basis for me. BUT ... can we make all of the closed topics go to the bottom ? I am using a forum as a to-do list , and when a topic has been solved, we close it. I would like the open topics (all of them) to be at the top.

Any Ideas ?

Top
#52637 - 04/19/05 04:18 PM Re: Closed topics to bottom
Zombie Offline
Newbie

Registered: 12/07/01
Posts: 13
What would be really cool is to have a display option to not show the closed topics at all

wink

Top
#52638 - 04/20/05 07:57 AM Re: Closed topics to bottom
Gizmo Offline

Wizard

Registered: 01/10/00
Posts: 5354
Loc: Portland, OR, USA
Quote:
Originally posted by Zombie:

What would be really cool is to have a display option to not show the closed topics at all

wink


There is one, it's called delete wink
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design & Development President
UBB.Threads: My UBBSkins, UBB.Sitemaps

Top
#52639 - 04/20/05 08:57 AM Re: Closed topics to bottom
Ian Spence Offline
Master Hacker

Registered: 01/25/03
Posts: 3765
Loc: Saint Johns, PA
you aren't getting a UI, but if you just don't do the last step from my earlier post, you'll get the desired results

Top



Moderator:  Gizmo 
Latest Posts
[7.2.1] - Naked shoutbox
by bellaonline
05/05/12 05:00 PM
[7.x] Stop Forum Spam Integration v0.4
by bellaonline
05/05/12 03:53 PM
Shout Box

(Views)Popular Topics
Known public proxy servers 1689885
Integrated Index Page (IIP) 5.3.1 555705
Finished-[6.5.2] Games Arcade Deluxe v1.9 501236
Integrated Index Page (IIP) 5.1.1 415112
TLD Bv2.1 Released - Threads Links Directory 396822
[6.0x] Who's Online 4.0.0 [Finished] 389412
Finished-[6.5.1] Integrated Index Page (IIP) 6.5 330423
Q & A 298663
Slash UBB 266936
[6.3.x] [beta] Hit Hack 2.0 227970
Forum Stats
13621 Members
59 Forums
37191 Topics
295716 Posts

Max Online: 686 @ 06/28/07 07:04 AM

 

 

 
fusionbb message board php hacks