Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions

Reply
 
Thread Tools Display Modes
  #11  
Old 11-16-2004, 09:01 PM
Michael Morris's Avatar
Michael Morris Michael Morris is offline
 
Join Date: Nov 2003
Location: Knoxville TN
Posts: 774
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Those are template conditionals. You put them in the template where the ad will appear along with the rest of the HTML. If you're ads going to be in the header, then it all goes in the $header template.

The name of the CPMS index is

adv_index

So the conditional is

HTML Code:
<if condition="THIS_SCRIPT=='adv_index'">ad code</if>
Reply With Quote
  #12  
Old 11-16-2004, 09:03 PM
Michael Morris's Avatar
Michael Morris Michael Morris is offline
 
Join Date: Nov 2003
Location: Knoxville TN
Posts: 774
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by DistributorTalk
Could you post the exact code you use to get those ads on your vbadvanced homepage and other pages at the top? Also let me know exactly where you place the code.
Our code won't work for you - if you use it you'll call up our ads

phpadsnew2 generates the ad code itself. Go to Publisher's & Zones and select "Generate Invocation Code" and use the "Remote invocation by javascript" - that's easier than trying to splice and php from phpadsnew into vbulletin.
Reply With Quote
  #13  
Old 11-16-2004, 09:33 PM
cmiller1014 cmiller1014 is offline
 
Join Date: May 2004
Posts: 248
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks Michael.

Just to clarify, my code will always go in the template for whichever page I want it to appear on, right?
Reply With Quote
  #14  
Old 11-16-2004, 09:42 PM
Michael Morris's Avatar
Michael Morris Michael Morris is offline
 
Join Date: Nov 2003
Location: Knoxville TN
Posts: 774
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

$header is global - meaning it's called on all pages. If you want 4 zones for four different pages you'll put the invocation codes for ALL of them in the header. Each one should be surrounded by the appropriate conditional tags. Hence

<if>Ad 1
<else /><if>Ad 2
<else /><if>Ad 3
<else />Ad 4
</if></if></if>
Reply With Quote
  #15  
Old 11-16-2004, 11:45 PM
cmiller1014 cmiller1014 is offline
 
Join Date: May 2004
Posts: 248
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok I got that part..... but now how does vbulletin know where to put the ad on the page? For example, if I want a little ad on the forum home page to show a "sponsor" for a specific category, I would somehow need to call that ad right next to the category name. So from what you have said I understand I need to put the conditions in the header template, but now what other code needs to be put (and where) to get the small ads to show up.

Thanks again
Reply With Quote
  #16  
Old 11-16-2004, 11:56 PM
Michael Morris's Avatar
Michael Morris Michael Morris is offline
 
Join Date: Nov 2003
Location: Knoxville TN
Posts: 774
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You put the code in the spot you want it to show up in. If you open a template, say forumhome, you're looking at an outline of the page before the values of any variables are plugged in. You put all that code at the location you want it. You may need to use tables for some additional formatting, depending on what you're looking for.
Reply With Quote
  #17  
Old 03-13-2005, 02:55 AM
cmiller1014 cmiller1014 is offline
 
Join Date: May 2004
Posts: 248
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi again,

Thanks for all your help, ive got one more question.

We ditched the vbadvanced page and dont need to worry about what ads are on what pages. We just need to be able to call 2 468x60 banners, and one or two small side banners for each page. Right now we are only able to call 1 large banner at the top.

Here is how we are doing it:

In the php_include section in styles we have:

Code:
require("/home/httpd/vhosts/distributortalk.com/httpdocs/ads/phpadsnew.inc.php"); 
$ads_array=view_raw("468x60");
Then on in the header template where we have the banner showing we have:

Code:
$ads_array[html]
This works great to call a random 468 banner at the top, but we want to call one more at the bottom, and then one of the small size ones on the side.

Thanks in advance!
Reply With Quote
  #18  
Old 05-26-2005, 06:15 AM
cmiller1014 cmiller1014 is offline
 
Join Date: May 2004
Posts: 248
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hey guys,

I decided to install phpadsnew on a different domain so that I can setup zones and have advertising across all of my sites. What would be the best way to call the ads into vbulletin now that I have it setup like this? Can you give me an example?
Reply With Quote
Reply

Thread Tools
Display Modes

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 03:41 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.03838 seconds
  • Memory Usage 2,221KB
  • Queries Executed 11 (?)
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
  • (2)bbcode_code
  • (1)bbcode_html
  • (1)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
  • (1)pagenav_pagelink
  • (8)post_thanks_box
  • (8)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (8)post_thanks_postbit_info
  • (8)postbit
  • (8)postbit_onlinestatus
  • (8)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_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