vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   3.5.4: Looking to remove banner ads for subscribers ... help! (https://vborg.vbsupport.ru/showthread.php?t=118171)

FastCougar 06-09-2006 09:56 PM

3.5.4: Looking to remove banner ads for subscribers ... help!
 
I'm currently running PHPAdsNew and it's working very well. I'm also using Google's AdSense. I also have "premium" members that I want to NOT show banners/AdSense ads for. I know it's probably a very simple IF statement, but I'm new to vBulletin and don't know how to impliment this. How would I go about doing this?

Ted S 06-10-2006 12:55 AM

Code:

<if condition="!is_member_of($bbuserinfo,X)">
Adsense Code
</if>

Change X to your premium usergroup.

FastCougar 06-10-2006 04:49 AM

Thank you!

FastCougar 06-12-2006 03:53 PM

Everything is working great, but now I have another requirement:

I want to allow members of the subscription to choose if they want to view ads or not. Now, from what I have been able to dig up, I can't associate profile questions with particular member groups. If I enter a profile question, it's seen by all users. Is this correct? If so, how would I go about allowing paying users to choose if they want to view banner ads or not?

bada_bing 06-20-2006 06:14 PM

Quote:

Originally Posted by Ted S
Code:

<if condition="!is_member_of($bbuserinfo,X)">
Adsense Code
</if>

Change X to your premium usergroup.

This did not work for me

Mythotical 07-01-2006 08:04 AM

use if subscription adds user to secondary usergroup:
Code:

<if condition="$bbuserinfo[membergroupids] == X">

<else />
Adsense code
</if>

use if subscription adds user to new usergroup and no secondary:
Code:

<if condition="$bbuserinfo[usergroupid] == X">

<else />
Adsense code
</if>

EDIT: the else just states if the member is not part of the usergroup specified then ads will show.

Cheers
Steve


All times are GMT. The time now is 03:57 PM.

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.00970 seconds
  • Memory Usage 1,720KB
  • 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
  • (4)bbcode_code_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (6)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