Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Mod Name: Banner Ad Rotator 1.0
Description: This is a simple rotation tool, which pulls banners (or content) from a private forum and feeds it randomly into a box at the top of your site, just above your menu bar. There is an option to stick a particular banner, rather than using the random rotation, in the event of something you wish to promote, like a special or a sale.
Since this simply pulls post content... it could be used for anything... random quotes, joke of the day, etc... it simply pulls the post body... text or images.
Author: JoshPet of
www.joshuapettit.com For discussion and bug reports go to
www.ubbdev.com Credits: Commissioned by
www.drugbuyers.com Demo: www.measurection.com Date: 2/24/03
Working Under: 6.2
Files Modified: ubbt.inc.php
New Files: bannerad.php
Database Modifications: None
Notes: This allows you to store, add, edit or delete your banners just by adding or removing them from a forum. Simple interface.
Attachments
Joined: Jan 2002
Posts: 674
Junior Member
Junior Member
Joined: Jan 2002
Posts: 674
cool mod... can it be turned off and on?
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
If the "banner" forum is empty nothing will appear.
Joined: Jan 2002
Posts: 674
Junior Member
Junior Member
Joined: Jan 2002
Posts: 674
Cool I can just move them to a hidden forum... Thanks Josh another great mod
Joined: Apr 2002
Posts: 68
Power User
Power User
Joined: Apr 2002
Posts: 68
For some reason i'm getting this "Parse error: parse error in /www/prowrestlingforum.com/threads/bannerad.php on line 92"
"We're sorta like the 7-11. We're not always doin' business, but we're always open"
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
I can't see why there would be a parse error there. It's in the echo of the output, and halfway through it at that.
Did you do any editing?
Joined: Apr 2002
Posts: 68
Power User
Power User
Joined: Apr 2002
Posts: 68
Nope, i've installed it twice just to make sure that I didn't mess up the first time Well i've installed mods (not part of this)
"We're sorta like the 7-11. We're not always doin' business, but we're always open"
Joined: Jan 2002
Posts: 266
Member
Member
Joined: Jan 2002
Posts: 266
I'm getting it too. Have done the hack twice. []Parse error: parse error, unexpected $ in my directory/ubbthreads/bannerad.php on line 92 [/]Funny thing is... there is no $ on line 92. There is one on line 91 but it's a necessary one.
Last edited by Sasha; 03/11/2003 12:12 AM .
Joined: Jan 2002
Posts: 266
Member
Member
Joined: Jan 2002
Posts: 266
Any feedback on this yet?
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Ah I missed this.
Maybe making a template for it will solve the issue.
I'll look at this in a bit when I get time and see if that solves it.
Joined: Jan 2002
Posts: 266
Member
Member
Joined: Jan 2002
Posts: 266
Thank you, I appreciate it..
I was all set to go with this... even had the first banner of "This space for rent" all made up.
Joined: Jan 2002
Posts: 266
Member
Member
Joined: Jan 2002
Posts: 266
Hate to be a PITA on this... but I really, really need this one... really! Any chance of figuring out what that parse error means and how to fix it? Please? (if I could find a begging smilie, I'd insert it here)
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Ah I'd forgotten. I"ll take a look in a bit.
Joined: Jan 2002
Posts: 266
Member
Member
Joined: Jan 2002
Posts: 266
Thanks much!!!
Joined: Apr 2002
Posts: 68
Power User
Power User
Joined: Apr 2002
Posts: 68
thanks, I'm waiting for the fix too.
"We're sorta like the 7-11. We're not always doin' business, but we're always open"
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Sasha, caspe7... I'm kind of stumped on this...as the error is within the HTML. But I changed this to use a template instead. Try this and see if it works (attached to this post). Let me know. This has a template file to be put in /templates/default directory.
Attachments
Joined: Jan 2002
Posts: 266
Member
Member
Joined: Jan 2002
Posts: 266
I'm trying it. I'll report back in a few minutes.
Joined: Jan 2002
Posts: 266
Member
Member
Joined: Jan 2002
Posts: 266
Now I have this error: []Parse error: parse error, unexpected $ in my directory/ubbthreads/templates/default/banner.tmpl on line 17[/]
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
I'm stumped why this doesn't work for some people. I called in the calvary
here .
One last thing you could try. The couple of variables in the Template file... place them inside brackets, like this {$banner}
Worth a shot.
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Dave_L posted something for you to try in
that other thread . Me testing does no good.... because it always worked for me.
I posted in the PHP board because I figurd I'd done something wrong.... but If I did Dave_L didn't notice it. But maybe there is something offensive in the banner itself.
Let us know.
Joined: Apr 2002
Posts: 68
Power User
Power User
Joined: Apr 2002
Posts: 68
Thanks, I did what it said in the other topic, I think I messed it up (where I put it), and it showed it couple of times (2 out of place, 1 the normal place), so i deleted it and It worked how it should, don't know why
"We're sorta like the 7-11. We're not always doin' business, but we're always open"
Joined: Apr 2002
Posts: 68
Power User
Power User
Joined: Apr 2002
Posts: 68
I got a question now that it works
Is there a simple way, to be able to turn it off on a user? forexample if someone hated it so much (if they are on a 56k) that they would pay money to have it removed.
(I know theres the sidebar that can do that, but I didn't like the sidebar too much
some reason it made everything look odd)
"We're sorta like the 7-11. We're not always doin' business, but we're always open"
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
I've done that on my site.
I include it on the top and bottom of every page. If they are a paid supporter... they have the option of turning the top banner off.
I haven't written up the code yet. If I can get to it, I will do it and post it.
Joined: Mar 2003
Posts: 2
Lurker
Lurker
Joined: Mar 2003
Posts: 2
It appears to be just a problem in using the echo command. I get the same compilation error. But the fix is simple enough just replace the echo block at the end:
<br />echo <<<BANNER<br /> $tbopen<br /> <tr><br /> <td align="center" class="darktable"><br /> <b>Support Our Site - $Title</b><br /> </td><br /> </tr><br /> <td align="center" class="lighttable"><br /> $Banner<br /> </td><br /> </tr><br /> $tbclose<br /> <br /><br />BANNER;<br /> with simple print statements, not as pretty, but it does compile:
<br />print( $tbopen);<br />print( "<tr>\n");<br />print( "<td align=\"center\" class=\"darktable\"> \n");<br />print( "<b>Support Our Site - $Title</b>\n");<br />print( "</td>\n");<br />print( "</tr>\n");<br />print( "<td align=\"center\" class=\"lighttable\">\n");<br />print( "$Banner\n");<br />print( "</td></tr>$tbclose<br />\n");<br />
Joined: Jan 2002
Posts: 266
Member
Member
Joined: Jan 2002
Posts: 266
Works like a charm! Thanks James...
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Thank you.
Joined: Aug 2002
Posts: 218
Member
Member
Joined: Aug 2002
Posts: 218
[]
JoshPet said: I've done that on my site.
I include it on the top and bottom of every page. If they are a paid supporter... they have the option of turning the top banner off.
I haven't written up the code yet. If I can get to it, I will do it and post it.
[/]
Oh yes Josh, can you please do so?
Would be nice if the banner will only be shown for some usergroups and not for all.
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Works for 6.3 - reposted
here .
Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.
Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Posts:
5,834
Joined: January 2000
Forums63
Topics37,575
Posts293,931
Members13,824
Most Online6,139Sep 21st, 2024
Currently Online
Topics Created
Posts Made
Users Online
Birthdays