The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Using PHPadsnew 2 with Vbulletin 3.
The following are some tips on using these two programs together, based on my own experience. It's expected that you know how to use phpadsnew 2 to set up ads and generate invocation code. PHP Invocation The first tip is how to use php invocation code. Using javascript is possible, but not all browsers support javascript and, in my experience, using php is faster. The php invocation code phpadsnew generates will look something like this... PHP Code:
PHP Code:
If you have multiple zones, you can string these together. On EN World we have a zone that only appears on our vbadvanced news page. On those pages we call the view_raw function an additional time for the extra zone (view_raw is the function that actually calls up the ad - the rest of the code initializes phpadsnew). Here's our code, as an example of a 2 zone system. PHP Code:
Ads new's maintenance.php file needs to run on a regular basis for it to perform correctly. You can invoke it from your scheduled task manager if you wish. If you do, I'd advise applying the following mod to the code of the maintenance.php file. Open it and go to the ending ?> mark. Right about it add this. PHP Code:
Any other tips/comments/questions welcomed. PHP Ads New 2 is at http://www.phpadsnew |
#102
|
|||
|
|||
<a href="https://vborg.vbsupport.ru/showthread.php?t=100229" target="_blank">https://vborg.vbsupport.ru/showthread.php?t=100229</a>
phpAdsNew Integration 1.0.3 for vBulletin 3.5.x |
#103
|
|||
|
|||
Anyone know how to place phpadsnew banners in one zone and rotate like this forum www.ls1tech.com
I picked "Don't show a banner from the same campaign again on the same page" And put my php generated local mode in global and put my banner code in right_column > $phpAds_raw2[html] > $phpAds_raw3[html] > $phpAds_raw4[html] > $phpAds_raw5[html] > $phpAds_raw6[html] > $phpAds_raw7[html] > $phpAds_raw8[html] > $phpAds_raw9[html] > $phpAds_raw10[html] > $phpAds_raw11[html] > $phpAds_raw12[html] I'm getting doubles still of my banners, there must be a setting in phpadsnew to fix this so I don't get doubles, anyone know? Here's my site www.sembmusclecarclub.com |
#104
|
||||
|
||||
When I was using 3.0.6 I had phpds working real well it it. When I upgraded to 3.6 -- they disappeared. I added the phpinclude_start template -- but that didn't help.
COde in the phpinclude_start Code:
if (@include(getenv('DOCUMENT_ROOT').'/phpad/phpadsnew.inc.php')) { if (!isset($phpAds_context)) $phpAds_context = array(); $phpAds_raw = view_raw ('zone:1', 0, 'new', '', '0', $phpAds_context); $phpAds_context[] = array('!=' => 'bannerid:'.$phpAds_raw['bannerid']); } if (@include(getenv('DOCUMENT_ROOT').'/phpad/phpadsnew.inc.php')) { if (!isset($phpAds_context)) $phpAds_context = array(); $phpAds_raw2 = view_raw ('zone:1', 0, 'new', '', '0', $phpAds_context); $phpAds_context[] = array('!=' => 'bannerid:'.$phpAds_raw2['bannerid']); } if (@include(getenv('DOCUMENT_ROOT').'/phpad/phpadsnew.inc.php')) { if (!isset($phpAds_context)) $phpAds_context = array(); $phpAds_raw3 = view_raw ('zone:1', 0, 'new', '', '0', $phpAds_context); $phpAds_context[] = array('!=' => 'bannerid:'.$phpAds_raw3['bannerid']); } if (@include(getenv('DOCUMENT_ROOT').'/phpad/phpadsnew.inc.php')) { if (!isset($phpAds_context)) $phpAds_context = array(); $phpAds_raw4 = view_raw ('zone:1', 0, 'new', '', '0', $phpAds_context); } if (@include(getenv('DOCUMENT_ROOT').'/phpad/phpadsnew.inc.php')) { if (!isset($phpAds_context)) $phpAds_context = array(); $phpAds_raw5 = view_raw ('zone:1', 0, 'new', '', '0', $phpAds_context); } if (@include(getenv('DOCUMENT_ROOT').'/phpad/phpadsnew.inc.php')) { if (!isset($phpAds_context)) $phpAds_context = array(); $phpAds_raw6 = view_raw ('zone:1', 0, 'new', '', '0', $phpAds_context); } if (@include(getenv('DOCUMENT_ROOT').'/phpad/phpadsnew.inc.php')) { if (!isset($phpAds_context)) $phpAds_context = array(); $phpAds_raw7 = view_raw ('zone:18', 0, 'new', '', '0', $phpAds_context); echo $phpAds_raw['html']; } if (@include(getenv('DOCUMENT_ROOT').'/phpad/phpadsnew.inc.php')) { if (!isset($phpAds_context)) $phpAds_context = array(); $phpAds_raw8 = view_raw ('zone:18', 0, 'new', '', '0', $phpAds_context); echo $phpAds_raw['html']; } Code:
<!-- Add three phpad banners --> $phpAds_raw[html] $phpAds_raw2[html] $phpAds_raw3[html] </td> </tr> </table> </center> </div> <!-- Endphpad banners--> Is there a was to use php invocation code in a 3.6 template -- more simular to the way I did in 3.0.6? Quote:
|
#105
|
||||
|
||||
Sure hoping that someone gets this figured out for vB 3.6.x.
I'd hate to throw away phpAdsNew. |
#106
|
|||
|
|||
anyone got a fix for 3.6 ?
|
#107
|
|||
|
|||
Hi i finally made it work by myself for vbulletin 3.6.0
1. Make a new plugin with the code phpAdsNew generates OMMITING the last echo command. ex PHP Code:
3. Save the plugin Now find the template you want and add: PHP Code:
Finished! it works ! (i tested it) (check www.pbzone.net) if you want more info email me onliner AT pbzone.net thanks |
#108
|
||||
|
||||
Quote:
I don't see this working on your site with the link you provided. Also, I made my local mode code: ?php if (@include(getenv('DOCUMENT_ROOT').'/phpadsnew/phpadsnew.inc.php')) { if (!isset($phpAds_context)) $phpAds_context = array(); $phpAds_raw = view_raw ('', 23, '_blank', '', '0', $phpAds_context); echo $phpAds_raw['html']; } ?> Integrated it into the code you put out: ob_start(); if (@include(getenv('DOCUMENT_ROOT').'/phpadsnew/phpadsnew.inc.php')) { if (!isset($phpAds_context)) $phpAds_context = array(); $phpAds_raw = view_raw ('', 23, '_blank', '', '0', $phpAds_context); echo $phpAds_raw['html']; } ob_end_clean(); Added this code into my global_start. Then, added: {$phpAds_raw['html']} Into my forumhome template. Still not working, but then again, I'm using vB 3.6.1 Ideas? Thanks Thanks |
#109
|
|||
|
|||
you need to delete the line
echo $phpAds_raw['html']; from your plugin!! check over the navbar http://www.pbzone.net/forum/index.php |
#110
|
||||
|
||||
Quote:
http://www.f-bodyhideout.com/forums/forum.php The issue now is that it shows up in two different areas on the forumhome template......mmmm, when I click on any other forum or category....then it shows up only once, like it's suppose to do. Strange... Thoughts? Thanks, Mark |
#111
|
|||
|
|||
you prolly have the same code somewhere else too? do a search mate
|
Thread Tools | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|