Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #11  
Old 06-10-2007, 02:48 AM
Dismounted's Avatar
Dismounted Dismounted is offline
 
Join Date: Jun 2005
Location: Melbourne, Australia
Posts: 15,047
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by ski diva View Post
Yes.

Here's an example of the code:
Replace the two instances of "zone:3" with:
Code:
zone:<if condition="$foruminfo['forumid'] == FORUMID">ZONENUMBER<else />3</if>
To do this with multiple forums:
Code:
zone:<if condition="$foruminfo['forumid'] == FORUMID">ZONENUMBER<else /><if condition="$foruminfo['forumid'] == FORUMID2">ZONENUMBER2<else />3</if></if>
Reply With Quote
  #12  
Old 06-11-2007, 11:54 PM
ski diva ski diva is offline
 
Join Date: Jun 2006
Posts: 208
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks, Dismounted, but this doesn't seem to work; all it seems to do is remove the ad from all the forums instead of allowing me to deliver a specific ad to a specific forum.

I must be doing something wrong, but I don't know what it is.

And tobybird: I'm not trying to do contextual advertising. It's more straightforward than that; what I want to do is have the ads vary by forum. For example, if there's a "gardening" forum, I want to have a specific gardening ad there. If there's a "cooking" forum, the ad would be different. Or maybe have I'd have all the forums with the same ad, except for one.

HELP!!!!!
Reply With Quote
  #13  
Old 06-12-2007, 09:27 AM
Dismounted's Avatar
Dismounted Dismounted is offline
 
Join Date: Jun 2005
Location: Melbourne, Australia
Posts: 15,047
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You need to create multiple zones and replace the capitalised words in the code I gave you.
Reply With Quote
  #14  
Old 06-12-2007, 05:39 PM
ski diva ski diva is offline
 
Join Date: Jun 2006
Posts: 208
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Let me try to restate my problem, so that I can take advantage of the help you're trying to give me!

All of my forums draw from the same template. There are a dozen different forums, to each of which I would like to deliver a specific banner. The Cooking forum gets a Cooking ad. The Ratkilling forum gets a Ratkilling ad. And so on.

Right now, I can only deliver the same ad (or range of ads) to all forums. Which is fine if I have an advertiser who sells both Cooking and Ratkilling equipment.

How can I specify which goes where?
Reply With Quote
  #15  
Old 06-13-2007, 09:36 AM
Dismounted's Avatar
Dismounted Dismounted is offline
 
Join Date: Jun 2005
Location: Melbourne, Australia
Posts: 15,047
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You need to setup multiple zones to match the forums and use the code I gave you to assign a different zone to each forum.
Reply With Quote
  #16  
Old 06-13-2007, 02:19 PM
ski diva ski diva is offline
 
Join Date: Jun 2006
Posts: 208
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Sorry to be so dense about this (you're being so helpful), but I must be doing something wrong. I established another zone and put the invocation code for it in the forumdisplay template, below the code for the first zone. Then I changed the invocation code in the first zone, as you suggested, and all that happens is I get the same ad going to all forums (the one I wanted to target to a specific forums). Maybe you could take a look and let me know what I'm doing wrong? I'd appreciate the help:

Quote:
<script language='JavaScript' type='text/javascript' src='http://www.XXXXXXX.com/openads/adx.js'></script>
<script language='JavaScript' type='text/javascript'>
<!--
if (!document.phpAds_used) document.phpAds_used = ',';
phpAds_random = new String (Math.random()); phpAds_random = phpAds_random.substring(2,11);

document.write ("<" + "script language='JavaScript' type='text/javascript' src='");
document.write ("http://www.XXXXXXX.com/openads/adjs.php?n=" + phpAds_random);
document.write ("&amp;what=zone: <if condition=”$foruminfo [ ‘forumid’ ] == id:11”>zone:7<else />3</if>");
document.write ("&amp;exclude=" + document.phpAds_used);
if (document.referrer)
document.write ("&amp;referer=" + escape(document.referrer));
document.write ("'><" + "/script>");
//-->
</script><noscript><a href='http://www.XXXXXXX.com/openads/adclick.php?n=a6409d73' target='_blank'><img src='http://www.XXXXXXX.com/openads/adview.php?what=zone: <if condition=”$foruminfo [ ‘forumid’ ] == id:11”>zone:7<else />3</if></if>&amp;n=a6409d73' border='0' alt=''></a></noscript>

<script language='JavaScript' type='text/javascript' src='http://www.theskidiva.com/openads/adx.js'></script>
<script language='JavaScript' type='text/javascript'>
<!--
if (!document.phpAds_used) document.phpAds_used = ',';
phpAds_random = new String (Math.random()); phpAds_random = phpAds_random.substring(2,11);

document.write ("<" + "script language='JavaScript' type='text/javascript' src='");
document.write ("http://www.XXXXXXX.com/openads/adjs.php?n=" + phpAds_random);
document.write ("&amp;what=zone:7");
document.write ("&amp;exclude=" + document.phpAds_used);
if (document.referrer)
document.write ("&amp;referer=" + escape(document.referrer));
document.write ("'><" + "/script>");
//-->
</script><noscript><a href='http://www.XXXXXXX.com/openads/adclick.php?n=a9afbf66' target='_blank'><img src='http://www.XXXXXXX.com/openads/adview.php?what=zone:7&amp;n=a9afbf66' border='0' alt=''></a></noscript>


Edited a little bit later:

I changed the code to the following:

zone:<if condition="$foruminfo['forumid'] == 11">7<else />3</if>

and now I'm getting both ads (side by side) in all forums. I only want the ad that's linked to zone 7 in one of the forums (in this case, id:11). The rest of the forums get the ad that's linked to zone 3

Any ideas?
Reply With Quote
  #17  
Old 06-14-2007, 06:59 AM
Dismounted's Avatar
Dismounted Dismounted is offline
 
Join Date: Jun 2005
Location: Melbourne, Australia
Posts: 15,047
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Code:
<script language='JavaScript' type='text/javascript' src='http://www.XXXXXXX.com/openads/adx.js'></script>
<script language='JavaScript' type='text/javascript'>
<!--
if (!document.phpAds_used) document.phpAds_used = ',';
phpAds_random = new String (Math.random()); phpAds_random = phpAds_random.substring(2,11);

document.write ("<" + "script language='JavaScript' type='text/javascript' src='");
document.write ("http://www.XXXXXXX.com/openads/adjs.php?n=" + phpAds_random);
document.write ("&amp;what=zone:<if condition="$foruminfo['forumid'] == 11">7<else />3</if>");
document.write ("&amp;exclude=" + document.phpAds_used);
if (document.referrer)
document.write ("&amp;referer=" + escape(document.referrer));
document.write ("'><" + "/script>");
//-->
</script><noscript><a href='http://www.XXXXXXX.com/openads/adclick.php?n=a6409d73' target='_blank'><img src='http://www.XXXXXXX.com/openads/adview.php?what=zone:<if condition="$foruminfo['forumid'] == 11">7<else />3</if>&amp;n=a6409d73' border='0' alt=''></a></noscript>

<script language='JavaScript' type='text/javascript' src='http://www.theskidiva.com/openads/adx.js'></script>
<script language='JavaScript' type='text/javascript'>
<!--
if (!document.phpAds_used) document.phpAds_used = ',';
phpAds_random = new String (Math.random()); phpAds_random = phpAds_random.substring(2,11);

document.write ("<" + "script language='JavaScript' type='text/javascript' src='");
document.write ("http://www.XXXXXXX.com/openads/adjs.php?n=" + phpAds_random);
document.write ("&amp;what=zone:<if condition="$foruminfo['forumid'] == 11">7<else />3</if>");
document.write ("&amp;exclude=" + document.phpAds_used);
if (document.referrer)
document.write ("&amp;referer=" + escape(document.referrer));
document.write ("'><" + "/script>");
//-->
</script><noscript><a href='http://www.XXXXXXX.com/openads/adclick.php?n=a9afbf66' target='_blank'><img src='http://www.XXXXXXX.com/openads/adview.php?what=zone:7&amp;n=a9afbf66' border='0' alt=''></a></noscript>
Reply With Quote
  #18  
Old 06-14-2007, 12:19 PM
ski diva ski diva is offline
 
Join Date: Jun 2006
Posts: 208
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Sorry to say this didn't work, either.

Any other ideas? I really need some help!
Reply With Quote
  #19  
Old 06-15-2007, 09:43 AM
Dismounted's Avatar
Dismounted Dismounted is offline
 
Join Date: Jun 2005
Location: Melbourne, Australia
Posts: 15,047
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

What happens?
Reply With Quote
  #20  
Old 06-15-2007, 11:45 AM
ski diva ski diva is offline
 
Join Date: Jun 2006
Posts: 208
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I get both ads side by side in all the forums, rather than one ad in all forums exccept one where it'd be replaced by the other ad.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 08:50 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.06778 seconds
  • Memory Usage 2,270KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (3)bbcode_code
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete