vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=251)
-   -   How do I tell VB NOT to display ads on custom page? (https://vborg.vbsupport.ru/showthread.php?t=285090)

jderouen 07-01-2012 12:31 AM

How do I tell VB NOT to display ads on custom page?
 
I created a custom VB page using Lynne's tutorial. It worked great! But now I need to make it so that ads don't show up on that page. Right now, we have an ad beneath the navbar and above the footer. What can I do to make these ads not show up on this custom page?

I originally posted the question on vBulletin.com, but as we decided it was a custom question am taking it here instead. Here's the thread from there: https://www.vbulletin.com/forum/show...88#post2310288

Any help would be most welcome!!

Thanks,
Joe

Andy 07-01-2012 12:55 AM

Hi Joe,

From the thread at vbulletin.com you indicated you have a script called museumlinks.php. Sounds like you need to also have a template called museumlinks. That way the code I provided will work.

Do you know how to create templates?

--------------- Added [DATE]1341109599[/DATE] at [TIME]1341109599[/TIME] ---------------

Hi Joe,

I was thinking about your question a bit more and having just gone through this on my site, what I did was end up only showing the banner on my forumhome and search pages. Would this work for you?

jderouen 07-01-2012 02:45 AM

I am working on this partially for someone else, I will ask re: the ads. Thanks!

Andy 07-01-2012 02:59 AM

Quote:

Originally Posted by jderouen (Post 2344191)
I am working on this partially for someone else, I will ask re: the ads. Thanks!

Be sure to mention that many of the pages like showthread, Private Messages etc., have problems when you put a banner under the navbar. So it's best to not show the banner accept on the two pages I mentioned.

Link14716 07-01-2012 03:10 AM

At the top of your custom file, look for the THIS_SCRIPT definition:
PHP Code:

<?php

// ####################### SET PHP ENVIRONMENT ###########################
error_reporting(E_ALL & ~E_NOTICE);

// #################### DEFINE IMPORTANT CONSTANTS #######################

define('THIS_SCRIPT''test');

Make sure that you have changed it from test to museumlinks. Then, use the if conditional given on vB.com to surround your advertising code:
Code:

<vb:if condition="THIS_SCRIPT != 'museumlinks'">
AD CODE HERE
</vb:if>


Andy 07-01-2012 04:18 AM

Very good Link14716. It's been so long since I created my home custom page I forgot all about the index.php file that I use as my default home page. I run the forum only package with a custom home page.


All times are GMT. The time now is 12:59 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.01159 seconds
  • Memory Usage 1,723KB
  • 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
  • (1)bbcode_code_printable
  • (1)bbcode_php_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