PDA

View Full Version : GAB on non-vB pages?


inthezone
11-08-2006, 01:16 AM
With GAB, can I place banners on non-vB pages (that is, pages that call global.php, but don't use any of vB's templates)?

The Geek
11-08-2006, 02:13 AM
If it calls global.php then yes, however you will need to still the output varibale somewhere (i.e. $GAB_ads[0] to see anything).
You will also need to make sure that the page has a THIS_SCRIPT def (e.g. define('THIS_SCRIPT', 'forumdisplay); )
Whatever it is defined as (forumdisplay in the above example) is the script name. You then need to add that name to GAB via admincp->gab->scripts->add new. Just enter the script name and make it use the master settings.

HTHs

Hornstar6969
11-11-2006, 07:18 AM
Just a quick question.

I'm using a cms that is non vbulletin, but I got it integrated into vbulletin recently. However to do this, I had to copy the whole includes folder from the forums and make a copy of it in the root directory (www) Because it was looking for the global.php file.

I tried changing the files to look in the forums, however then that caused other problems. Was there a special way to call for global.php that I should have used?

Also, I would like to integrate this into the non vb pages as well (in the cms)

Those above tips were a bit over my head, can someone give me another example (a little bit simpler would be nice) I didnt understand this part
however you will need to still the output varibale somewhere (i.e. $GAB_ads[0] to see anything).
You will also need to make sure that the page has a THIS_SCRIPT def (e.g. define('THIS_SCRIPT', 'forumdisplay); )
Whatever it is defined as (forumdisplay in the above example) is the script name.


Thanks for any tips I can get, it will be much appreciated.

The Geek
11-11-2006, 05:44 PM
What I would do (instead of copying all includes over) is :

chdir('forums/');
require_once('global.php');
chdir('../');


Basically, that changes your working directory to your forum directory... then runs global... then changes it back.

Ill try to do a tutorial on adding scripts. Its pretty straight forward once you get your head around it :)

Hornstar6969
11-21-2006, 07:58 AM
finally got time to do it.

It worked perfect. new I could count on you ^^

Thanks.