|
|
Joined: Mar 2000
Posts: 180
Member
|
Member
Joined: Mar 2000
Posts: 180 |
Is there a fairly simple way to make a new thread viewable only to a certain user group for a predetermined amount of time, then after the allotted time it is made viewable to the public?
Ex: we have a for sale section, and new for sale ads would be viewable *only* to the "paid members" group for 1 week, then after 1 week it would be made *public* and everyone could see the thread/post...
|
|
|
|
Joined: May 2001
Posts: 550
Code Monkey
|
Code Monkey
Joined: May 2001
Posts: 550 |
Do you want the new threads not to appear on the postlist at all, or do you want them to appear on the postlist, but once a public member clicks on it, he gets an error message?
|
|
|
|
Joined: Mar 2000
Posts: 180
Member
|
Member
Joined: Mar 2000
Posts: 180 |
Hmmm...I would say *either* would work?
|
|
|
|
Joined: May 2001
Posts: 550
Code Monkey
|
Code Monkey
Joined: May 2001
Posts: 550 |
ok, the first option first: in postlist.php
search for: $limit = "LIMIT $Totalgrab";
Add underneath: if (strpos($user[U_Groups], "-111-") === false && $Board == "boardkeyword" ){ $timeframe = time() - 7 * 86400; $timeframe = " AND t1.B_Posted < $timeframe "; }
search for: AND t1.B_Sticky = '0' Add underneath: $timeframe
That's it. Replace 111 with the number of your subscriber group, and boardkeyword with the keyword of the board where you want to enable this.
(untested, might not work, but it should)
|
|
|
|
Joined: Mar 2000
Posts: 180
Member
|
Member
Joined: Mar 2000
Posts: 180 |
Thanks, Anno...if/when I get some free time, I'm gonna give it a shot...
|
|
|
Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.
Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
|
|
Posts: 70
Joined: January 2007
|
|
Forums63
Topics37,573
Posts293,925
Members13,849
|
Most Online5,166 Sep 15th, 2019
|
|
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
|
|
|
|
|