(V88)Points Required To Enter Forum
Started by Vince, Apr 13 2008 09:40 AM
15 replies to this topic
#1
Posted 13 April 2008 - 09:40 AM
File Name: (V88)Points Required To Enter Forum
File Submitter: Vadim88
File Submitted: 13 Apr 2008
File Updated: 17 Apr 2008
File Category: IP.Board v2.3.x Mods
File Name: (V88)Points Required To Enter Forum
File Description: - Allows you to put a restriction on who have a certain amount of points needed to enter a certain forum.
- Control via ACP - Manage Forums - Add/Edit Forum - Min. number points required to enter the forum
Author: Vadim Gavrilov
File Version: 1.0
Requirements: Universal Mod Installer
Files Affected:
* ./lofiversion/index.php
* ./skin_acp/IPB2_Standard/acp_skin_html/cp_skin_forums.php
* ./sources/action_admin/forums.php
* ./sources/action_public/forums.php
* ./sources/action_public/search.php
* ./sources/action_public/topics.php
* ./sources/action_public/misc/attach.php
* ./sources/action_public/misc/forward_page.php
* ./sources/action_public/misc/print_page.php
* ./sources/classes/post/class_post.php
* ./sources/lib/func_usercp.php
Click here to download this file
File Submitter: Vadim88
File Submitted: 13 Apr 2008
File Updated: 17 Apr 2008
File Category: IP.Board v2.3.x Mods
File Name: (V88)Points Required To Enter Forum
File Description: - Allows you to put a restriction on who have a certain amount of points needed to enter a certain forum.
- Control via ACP - Manage Forums - Add/Edit Forum - Min. number points required to enter the forum
Author: Vadim Gavrilov
File Version: 1.0
Requirements: Universal Mod Installer
Files Affected:
* ./lofiversion/index.php
* ./skin_acp/IPB2_Standard/acp_skin_html/cp_skin_forums.php
* ./sources/action_admin/forums.php
* ./sources/action_public/forums.php
* ./sources/action_public/search.php
* ./sources/action_public/topics.php
* ./sources/action_public/misc/attach.php
* ./sources/action_public/misc/forward_page.php
* ./sources/action_public/misc/print_page.php
* ./sources/classes/post/class_post.php
* ./sources/lib/func_usercp.php
Click here to download this file
Vince Gabriel, Lead Developer.



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88
#2
Posted 17 April 2008 - 01:08 AM
Is this supposed to add the point_required to the Members table or the Forums table? I installed it normally but got IPS driver errors, so I added the field to Forums and it was ok. Or did I way off? I any case its working fine now.
If I wanted to add a user group or multiple usergroups who could bypass the minimum point rules, how would I add that to the code? This is what I came up with, whats wrong with it?
If I wanted to add a user group or multiple usergroups who could bypass the minimum point rules, how would I add that to the code? This is what I came up with, whats wrong with it?
if( ! $this->ipsclass->member['g_access_cp'] && ( $this->ipsclass->member['points'] < $this->forum['points_required'] ) && $this->ipsclass->member['mgroup'] ==95 )
{
$this->ipsclass->Error( array( 'LEVEL' => 1, 'MSG' => 'points_required', 'EXTRA' => $this->forum['points_required'] ) );
Edited by emoney, 17 April 2008 - 04:58 AM.
Anything4Free.com
Get stuff FREE!
emoneyCodes.com
I code
My 3.0 Releases: · (e$30) ibEconomy 1.2.0 · (e$30) Custom Sidebar Blocks 1.3.0 · (e$30) My Header Links Extended 0.9.5 · (e$30) PM Author on Topic Moderation 1.0.0 · (e$30) Post Author's Status 1.0.0 ·
My Classics: · (e$23) ibBookie 2.1.1 · (e$23) Personal Tags 1.5 · (e$23) Starred Topics and Messages 1.0 · (e$23) Disable Double Posting 1.0 · (e$23) Member Returns 1.0 ·
(e$23) Category Styles and Forum Title Colors 1.0.0 · (e$23) Members Online Scroller 1.0.0 · (e$23) Plain Text Posts 1.0 · (e$23) BBCodes Per Group 1.0 · (e$23) Default Profile Tab Per Member 1.0 · (e$23) March Madness ibBookie Plugin 2009 · (e$23) PM to Ticket 1.0 · (e$23) Reports as Tickets 1.0 · (e$23) Most Viewed Topics 1.0 ·
#3
Posted 17 April 2008 - 06:03 AM
Yes it should add points_required to the forums table, i think it does, i will check this out.
Yea something like this:
Yea something like this:
$groups = array(1,2,3,4);
if($this->ipsclass->member['points'] < $this->forum['points_required'] ) && ! in_array($this->ipsclass->member['mgroup'], $groups) )
{
$this->ipsclass->Error( array( 'LEVEL' => 1, 'MSG' => 'points_required', 'EXTRA' => $this->forum['points_required'] ) );
Vince Gabriel, Lead Developer.



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88
#4
Posted 17 April 2008 - 12:49 PM
I think that syntax was a bit off, but this worked:
$groups = array(4,37,10,119,148);
if ( $this->ipsclass->member['points'] < $this->forum['points_required'] && ! in_array($this->ipsclass->member['mgroup'], $groups) )
{
$this->ipsclass->Error( array( 'LEVEL' => 1, 'MSG' => 'points_required', 'EXTRA' => $this->forum['points_required'] ) );
}
And if its supposed to add points_required to Forums there is definitely an error in the xml. here is what all of your recent "XX Required to.."mods have basically:<alters_group> <alter> <alter_type>add</alter_type> <table>members</table> <field_name>post_required</field_name> <field_type>smallint(5)</field_type> <field_default>0</field_default> </alter>
Anything4Free.com
Get stuff FREE!
emoneyCodes.com
I code
My 3.0 Releases: · (e$30) ibEconomy 1.2.0 · (e$30) Custom Sidebar Blocks 1.3.0 · (e$30) My Header Links Extended 0.9.5 · (e$30) PM Author on Topic Moderation 1.0.0 · (e$30) Post Author's Status 1.0.0 ·
My Classics: · (e$23) ibBookie 2.1.1 · (e$23) Personal Tags 1.5 · (e$23) Starred Topics and Messages 1.0 · (e$23) Disable Double Posting 1.0 · (e$23) Member Returns 1.0 ·
(e$23) Category Styles and Forum Title Colors 1.0.0 · (e$23) Members Online Scroller 1.0.0 · (e$23) Plain Text Posts 1.0 · (e$23) BBCodes Per Group 1.0 · (e$23) Default Profile Tab Per Member 1.0 · (e$23) March Madness ibBookie Plugin 2009 · (e$23) PM to Ticket 1.0 · (e$23) Reports as Tickets 1.0 · (e$23) Most Viewed Topics 1.0 ·
#5
Posted 17 April 2008 - 02:40 PM
Just downloaded the points required and i had this:
<?xml version="1.0" encoding="ISO-8859-1"?> <mod_data> <mod_info> <title>(V88)Points Required To Enter Forum</title> <version>1.0.0</version> <author>vadim88</author> <website>http://www.invisionmodding.com/forums/</website> <ipbver>2.2</ipbver> </mod_info> <alters_group> <alter> <alter_type>add</alter_type> <table>members</table> <field_name>points_required</field_name> <field_type>smallint(5)</field_type> <field_default>0</field_default> </alter> </alters_group> <languages_group> <language> <key>points_required</key> <text><![CDATA[Sorry, you must have a total of <#EXTRA#> points or above to enter this forum.]]></text> <file>lang_error</file> </language> </languages_group> </mod_data>
Vince Gabriel, Lead Developer.



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88
#6
Posted 17 April 2008 - 02:55 PM
Ok, am I just reading that wrong? You said it has to add points_required to the forums table, but in your alters group it has:
<table>members</table>
shouldn't it be <table>forums</table> ?
<table>members</table>
shouldn't it be <table>forums</table> ?
Edited by emoney, 17 April 2008 - 02:55 PM.
Anything4Free.com
Get stuff FREE!
emoneyCodes.com
I code
My 3.0 Releases: · (e$30) ibEconomy 1.2.0 · (e$30) Custom Sidebar Blocks 1.3.0 · (e$30) My Header Links Extended 0.9.5 · (e$30) PM Author on Topic Moderation 1.0.0 · (e$30) Post Author's Status 1.0.0 ·
My Classics: · (e$23) ibBookie 2.1.1 · (e$23) Personal Tags 1.5 · (e$23) Starred Topics and Messages 1.0 · (e$23) Disable Double Posting 1.0 · (e$23) Member Returns 1.0 ·
(e$23) Category Styles and Forum Title Colors 1.0.0 · (e$23) Members Online Scroller 1.0.0 · (e$23) Plain Text Posts 1.0 · (e$23) BBCodes Per Group 1.0 · (e$23) Default Profile Tab Per Member 1.0 · (e$23) March Madness ibBookie Plugin 2009 · (e$23) PM to Ticket 1.0 · (e$23) Reports as Tickets 1.0 · (e$23) Most Viewed Topics 1.0 ·
#7
Posted 17 April 2008 - 06:38 PM
Oh darn...yes it should...thanks for that...sometimes my eyes are blurry.....
*of to fix...*
*of to fix...*
Vince Gabriel, Lead Developer.



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88
#8
Posted 17 April 2008 - 06:44 PM
Fixed.
Vince Gabriel, Lead Developer.



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88
#9
Posted 17 April 2008 - 07:12 PM
Anything4Free.com
Get stuff FREE!
emoneyCodes.com
I code
My 3.0 Releases: · (e$30) ibEconomy 1.2.0 · (e$30) Custom Sidebar Blocks 1.3.0 · (e$30) My Header Links Extended 0.9.5 · (e$30) PM Author on Topic Moderation 1.0.0 · (e$30) Post Author's Status 1.0.0 ·
My Classics: · (e$23) ibBookie 2.1.1 · (e$23) Personal Tags 1.5 · (e$23) Starred Topics and Messages 1.0 · (e$23) Disable Double Posting 1.0 · (e$23) Member Returns 1.0 ·
(e$23) Category Styles and Forum Title Colors 1.0.0 · (e$23) Members Online Scroller 1.0.0 · (e$23) Plain Text Posts 1.0 · (e$23) BBCodes Per Group 1.0 · (e$23) Default Profile Tab Per Member 1.0 · (e$23) March Madness ibBookie Plugin 2009 · (e$23) PM to Ticket 1.0 · (e$23) Reports as Tickets 1.0 · (e$23) Most Viewed Topics 1.0 ·
#10
Posted 17 April 2008 - 07:19 PM
Thanks will do.
Vince Gabriel, Lead Developer.



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88
#11
Posted 17 April 2008 - 10:33 PM
I just now realized that guests can't view any forum regardless of the minimum set. "They get the You need <EXTRA> more points to view this forum/" Is that supposed to be happening and if not, what could be the problem? I of course need at least part of my board open for guests.
edit: unless there is a better solution I'll just add the guest group number to the groups permitted line and then remove the guest permissions for any forum I set restrictions on. Let me know if there is a better solution.
edit: unless there is a better solution I'll just add the guest group number to the groups permitted line and then remove the guest permissions for any forum I set restrictions on. Let me know if there is a better solution.
Edited by emoney, 17 April 2008 - 11:43 PM.
Anything4Free.com
Get stuff FREE!
emoneyCodes.com
I code
My 3.0 Releases: · (e$30) ibEconomy 1.2.0 · (e$30) Custom Sidebar Blocks 1.3.0 · (e$30) My Header Links Extended 0.9.5 · (e$30) PM Author on Topic Moderation 1.0.0 · (e$30) Post Author's Status 1.0.0 ·
My Classics: · (e$23) ibBookie 2.1.1 · (e$23) Personal Tags 1.5 · (e$23) Starred Topics and Messages 1.0 · (e$23) Disable Double Posting 1.0 · (e$23) Member Returns 1.0 ·
(e$23) Category Styles and Forum Title Colors 1.0.0 · (e$23) Members Online Scroller 1.0.0 · (e$23) Plain Text Posts 1.0 · (e$23) BBCodes Per Group 1.0 · (e$23) Default Profile Tab Per Member 1.0 · (e$23) March Madness ibBookie Plugin 2009 · (e$23) PM to Ticket 1.0 · (e$23) Reports as Tickets 1.0 · (e$23) Most Viewed Topics 1.0 ·
#12
Posted 14 August 2008 - 10:52 AM
When you enter the forum, do you have to PAY the amount, or do you just NEED the amount...
#13
Posted 18 August 2008 - 07:38 AM
He will just need the amount set to enter, the points will not deduct from his account.
Vince Gabriel, Lead Developer.



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88
#14
Posted 19 August 2008 - 03:03 AM
Is there a way to make it so it will deduct the amount from his account only the first time he enters it?
#15
Posted 19 August 2008 - 07:02 AM
Not right now, No. But i am hoping to extend this for IPB 3.
Vince Gabriel, Lead Developer.



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88



Zend Certified Engineer.
Zend Framework Certified Engineer.
-- Email: vadimg88@gmail.com
-- Phone: +972-52-3808258
-- Skype: vadim.gabriel
-- Website: http://www.vadimg.com
formerly known as vadimg88
#16
Posted 08 September 2008 - 08:25 PM
emoney, on Apr 18 2008, 12:33 AM, said:
I just now realized that guests can't view any forum regardless of the minimum set. "They get the You need <EXTRA> more points to view this forum/" Is that supposed to be happening and if not, what could be the problem? I of course need at least part of my board open for guests.
Same problem here..anybody help please?
Edited by Turkulerdiyari, 08 September 2008 - 08:25 PM.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users





Contributor











