vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Paid Subscription by Usergroup (https://vborg.vbsupport.ru/showthread.php?t=97673)

clearchannel 10-05-2005 10:47 PM

Paid Subscription by Usergroup
 
I would like to allow specfic usergroups access to purchase a subscription(s)

It worked great in 3.07 by editing the subscription.php file. I can no longer find they syntax I changed in 3.07.

Is this possible to do in 3.50?

Thank you in advance.

Chris M 10-05-2005 10:51 PM

subscription.php is now payments.php in vB 3.5 :)

Chris

clearchannel 10-06-2005 12:04 AM

The code is different from version 3.07 to 3.50. Would you have a suggestion for allowing just one usergroup to use the paid subscriptions?

The code I changed perviously is

from
Code:

if ($bbuserinfo['userid'] == 0)
to
Code:

if (!is_member_of($bbuserinfo, 10))
10 being the usergroup allowed to used paid subscriptions.

Thanks in advance.

clearchannel 10-08-2005 10:59 PM

Whould anyone have a suggestion for allowing one specfic usergroup to purchase a paid subscription?

UK Jimbo 10-08-2005 11:48 PM

Untested...

You should be able to add the following conditional statement around the payment link in templates to prevent it appearing to users who aren't in group 10. Any code inbetween these two tags will only appear to member of group 10.

HTML Code:

<if condition="is_member_of($bbuserinfo, 10)">
HTML Code:

</if>
You can also prevent users who aren't in that group from accessing the page itself by adding a new plugin with the hook location paidsub_start

PHP Code:

if(! is_member_of($vbulletin->userinfo,10) ) {
    
print_no_permission();


This should show an error message for users that aren't in group 10 preventing them from seeing the page.

clearchannel 10-10-2005 07:05 PM

I apologize, this may be above my skill level :o

Would you be so kind as to provide more detail.

Thank you in advance.

UK Jimbo 10-10-2005 10:05 PM

1 Attachment(s)
Download the attached plugin to your computer.

Now install it on your system (Plugin system -> Download / Upload Plugins).

Only users of usergroup 10 will be able to access the plugin system

clearchannel 10-10-2005 11:24 PM

Thank you very much. That works like a champ. I truely do appericate your assistance.


All times are GMT. The time now is 07:04 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.00982 seconds
  • Memory Usage 1,724KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (2)bbcode_html_printable
  • (1)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete