Version: 1.00, by Scott MacVicar
Developer Last Online: Mar 2016
Version: 2.2.x
Rating:
Released: 05-25-2002
Last Update: Never
Installs: 47
No support by the author.
This is a script to allow you to manage the adverts on your forums, you can have any sort of advert you can imagine there is no actual limit with this hack to what it can be, javascript, flash, image, text and images.
You add adverts to a category or a forum or the whole board. If the category has child forums they will inherit the adverts as well as their own adverts if they have any.
Adverts can have a set exposure such as 10,000 views and once it has reached that it will stop.
It fills a variable called $advert which you just place in any template, such as the header, you can also use variables and replacements within the adverts, such as $bbuserinfo[userid] for the persons userid in a link within an advert.
Updated June 9th at 19:44 GMT
Added date limits and options for unlimited exposures.
To upgrade from an older version, reapply code in global.php, upload ads.php and run this sql query to alter the ads table you made.
[sql]ALTER TABLE `ads` ADD `time` INT(10) DEFAULT '0' NOT NULL;[/sql]
[sql]ALTER TABLE `ads` ADD `wholeforum` SMALLINT(1) DEFAULT '0' NOT NULL;[/sql]
If you already run that query though are still experiencing problems with the time always being January 1st run
New features include showing the advert on the entire forum by using a radio button, some highlighting in the admin panel, italic name indicates the time period has ended and a bold name means the advert has met its quota for exposures.
You must chance RAND() to RAND(NOW()) if you have mysql 3.23.52 or above
Scott
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
Bah thats my bad, i set $forumid in the global code, i'll change that until then em thats broken
WIll update it in a bit.
Will do some of the suggestions, To pick multiple forums might cause a problem cause the query will be more complicated but i should be able to find something.
Ive updated it now, sorted the forumid problem. Added unlimited exposures and the time limit.
The next problem is multiple banners and I've decided that allowing it for multiple forums would prove too dificult after some testing was done but I'll consult some people just to be sure.
Looking good. I have it installed and is working just fine on my board. Your new coding resolved the issue with the move/copy/move thread with redirect issue I was having.
I am not sure if this is a bug or not or just something not working right on my board but when I installed it before midnight the time limit function correctly identified the server date and worked great. Then I noticed that the banners stopped showing up after midnight and when I went to edit the file the stop date was listed as January 1 2001. If I reset this to today's date it would revert back to the January 1 2001.
Getting it to 2001 is a good trick since there isn't any in the code
You'll need to update all old ads with a time period, setting it today wont work as its based on 12am that day, so by the time you add it, its already happened.