vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Adsense Revenue Sharing Hack 1.1 (0 queries version) (https://vborg.vbsupport.ru/showthread.php?t=80685)

AlexanderT 05-10-2005 06:55 PM

Quote:

Originally Posted by Polo
good questions ;) yes, each person must have adsense (to put their id in their usercp pannel) and second well I really dont think so... I think it may be possible, but this hack I dont think supports that right now :)

It would be rather easy to implement that. But the question do you really want to click on any google ads appearing on your site? Why taking the risk? If you have a site with a lot of visitors, your own clicks would be marginalized anyways. I am currently using this hack only for my editors, and it is a policy on my board that noone of us clicks on ads appearing on our site.

venomx 05-10-2005 07:38 PM

Couldnt we do something like...

If $post[ad_client_id] = users fieldX>
DIFFERENT AD HERE (NON-Adsense)
else

Show the adsense ads
</if>

I would test but I dont know how to get the fieldX of the user viewing... :(

biagrin 05-10-2005 08:27 PM

well basically to sum up what i would like to see added:

adsense rotation being split between admin and thread starter only. that way the thread starter would know that the ad is either his account or admin account. that would instantly remove any problems.

yb the way when i tried to install it i followed the instructions to the dot but for some reason after it had been installed, when i tried to view a post i just got a warning saying something like "unexpected string /forums/showthread.php on line 31" which is where it says 'adsensesettings'

any idea what i have done wrong?

AlexanderT 05-10-2005 09:05 PM

Quote:

Originally Posted by biagrin
well basically to sum up what i would like to see added:

adsense rotation being split between admin and thread starter only. that way the thread starter would know that the ad is either his account or admin account. that would instantly remove any problems.

And that is how it is currently implemented.

Quote:

something like "unexpected string /forums/showthread.php on line 31" which is where it says 'adsensesettings'
Do you have other hacks installed? Can you show us the line above and below 'hidprofilecache' (around line 30, before you applied my hack)? If you don't have any other hacks installed, make sure to follow the instruction closely:
Code:

Find:
      'hidprofilecache'

REPLACE IT with:
      'hidprofilecache',
      'adsensesettings'

(e.g. don't forget to add the comma after 'hidprofilecache').

venomx 05-10-2005 09:05 PM

Quote:

Originally Posted by biagrin
well basically to sum up what i would like to see added:

adsense rotation being split between admin and thread starter only. that way the thread starter would know that the ad is either his account or admin account. that would instantly remove any problems.

I think thats the way it is. Plus it never shows the Thread starter his own if you used the right if conditional I believe...

biagrin 05-10-2005 10:30 PM

ok i get this error now

"parse error: unexpected T_ELSE"

meaning the else in this code
Code:

{
                                $post['ad_client_id'] = $post['field11'];
                                if (!empty($post['field12'])) {
                                        $post['ad_channel'] = $post['field12'];
                                }
                        }
                        else {
                                $post['ad_client_id'] = $adsensesettings['clientid'];
                                if (!empty($adsensesettings['channel'])) {
                                        $post['ad_channel'] = $adsensesettings['channelid'];


AlexanderT 05-10-2005 10:35 PM

biagrin that excerpt isn't really helpful. Did you include the entire snippet as was described in step 6? Also make sure you add it just below $FIRSTPOSTID = $post['postid']; (as was also described in 6).

biagrin 05-10-2005 10:48 PM

well for some reason its working now even though i done the same thing as last time.

thanks for the help mate i really appreciate it. :) im new to all this.

one last thing (i hope :) )

how do i set it so that EVERY user group sees the ads but will NEVER see their own ads.

for example: bob makes a thread. his account is picked randomly. he doesnt see the ad but i do.

next time bob view the thread, my account is shown and he sees it but i dont.

beano33 05-12-2005 02:00 PM

Anyone get this to work in the showthread template so the ad shows after the last post instead of the first as I asked in this post:
https://vborg.vbsupport.ru/showpost....9&postcount=32

CallieJo 05-13-2005 12:29 PM

Quote:

Originally Posted by beano33
You can use conditionals in the modifyoptions template so the new profile fields added are only visable for the usergroups you want.

See #2 in this thread

I am trying this but the instructions are not sinking in very good. Like here:

Quote:

This profile field needs to be the only custom profile field under the selected options category. Any other custom profile fields in the same category will be hidden as well.
I have more than one under edit profile.

Quote:

Go to your:

Admin CP -> Styles & Templates -> Style Manager -> ? ? -> Modify User Option Templates -> modifyoptions

In this template you will find several $customfields variables, one for each category in your options (the same categories as the ones for your profile fields). You need to enclose the appropriate $customfields variable with this conditional:
I go here and I do not understand what category? Is it edit profile? And where or what is it called in here?

Thanks!


All times are GMT. The time now is 06:40 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.01333 seconds
  • Memory Usage 1,750KB
  • 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
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete