vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.5 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=113)
-   -   Banner Rotator (Definitive Mod) (https://vborg.vbsupport.ru/showthread.php?t=103477)

andrefedalto 12-20-2005 10:00 PM

Banner Rotator (Definitive Mod)
 
Hi you there. I was looking for a really nice Banner Rotator Mod, but i couldn't find one that had what i need. So i decided to code one. Finished it right now and i'll share with you.

So, what does this hack do?
- This mod allows you to add lots of forum banners.
- The banners will be automatically randomized everytime you reload your forums.

How can i work with it?
- It's all controlable through AdminCP.
- NOT NEEDED ftp access to upload banners.
- You CAN upload banners (jpg, gif & png) through AdminCP.
- You can set a description for individual banners.
- You can edit the description easily and individually.
- You can delete the banners through AdminCP (this function delete the banner from the ftp)
- You can activate/deactivate you banners.
- Deactivated banners remains in the ftp, but will not be shown on forum home.

How can i install? (Time to install: 1 minute if you are fast enough :))
- Upload all the files contained in the "upload" folder inside the zip to your forum root directory and CHMOD 77 the folder "/image/banners"
- Install product-brotator.
- Go to your AdminCP > Style Manager > YOUR SKIN > Edit HEADER template and find:
Code:

<img src="$stylevar[titleimage]" border="0" alt="$vboptions[bbtitle]" />
Replace with:
Code:

<center>$banner</center>

You can change banner width and height editing the plugin called "Banner Rotator Generator" and changing the values:
Code:

width=879 height=160
for your own values.

I really hope you enjoy this hack and, please, if you find any kind of bug, report it to me as soon as possible.
And if you have any suggestions, post here.

Thanks you all!

GoTTi 12-21-2005 08:07 PM

thats a good hack.

try www.phpadsnew.com for probably the best banner management system out. and its free.

Daniel 12-21-2005 08:36 PM

I had a template modification like it, https://vborg.vbsupport.ru/showthrea...threadid=99402

Great job though!

rb290 12-21-2005 09:04 PM

Database error in vBulletin 3.5.2:

Invalid SQL:
SELECT * FROM brotator WHERE active = '1' ORDER BY Rand() LIMIT 1;

MySQL Error : Table 'thug_thug.brotator' doesn't exist
Error Number : 1146
Date : Wednesday, December 21st 2005 @ 06:03:38 PM

rb290 12-21-2005 09:07 PM

cant get on the board, gives me database error, can someone tell me whats wrong, when i uploaded a pic from the admincp it gave me a database error

jrofosho 12-21-2005 09:13 PM

my database tables weren't created either.

andrefedalto 12-21-2005 09:18 PM

apparently the tables weren't created. take a look at you db sctructure and look for any "brotator" table you find. if you want, give me your msn and i can fix that for you

jrofosho: same to you.. tables were not created. look for table brotator or ive me a way to contact you, like msn

thanks

rb290 12-21-2005 09:19 PM

msn: da_shiznit29@hotmail.com

jrofosho 12-21-2005 09:26 PM

msn: jrofosho@gmail.com

rb290 12-21-2005 09:40 PM

??????????

jrofosho 12-21-2005 10:14 PM

Issue resolved.

Nice hack.

Synth 12-21-2005 11:54 PM

Will this still allow affiliates to track activity on a banner?

Itworx4me 12-22-2005 04:39 AM

Would be a nice addition if it had banner clicks and a way to show stats to your advertisers.

DS MrSinister 12-22-2005 04:40 AM

this hack is for your banner at the top of your page. its like what vb.org has done with ther banners. how it changes when u click on to a another link etc.

andrefedalto 12-22-2005 09:44 AM

Quote:

Originally Posted by Itworx4me
Would be a nice addition if it had banner clicks and a way to show stats to your advertisers.

its not an advertisement mod... just main forum banner ;)

you can find plenty of ad mods :)

16ggst 12-22-2005 11:13 PM

im stupid.. where do i manage this banners in the admincp

andrefedalto 12-22-2005 11:32 PM

Quote:

Originally Posted by 16ggst
im stupid.. where do i manage this banners in the admincp

a small box will appear there, called BANNER ROTATOR, just like other submenus on the AdminCP

16ggst 12-23-2005 02:36 AM

sorry i forgot to do something thanks

newfun 12-23-2005 09:24 AM

Database error in vBulletin 3.5.2:

Invalid SQL:
UPDATE brotator SET active = '0' WHERE id = '1';

MySQL Error : Table 'forums.brotator' doesn't exist
Error Number : 1146
Date : Saturday, December 24th 2005 @ 12:22:26 AM
Script : http://localhost/forums/admincp/bann...activate&bid=1
Referrer :
IP Address : 127.0.0.1
Username : admin
Classname : vB_Database

I found this error? How can we fix that? plzzz

andrefedalto 12-23-2005 10:13 AM

Quote:

Originally Posted by newfun
Database error in vBulletin 3.5.2:

Invalid SQL:
UPDATE brotator SET active = '0' WHERE id = '1';

MySQL Error : Table 'forums.brotator' doesn't exist
Error Number : 1146
Date : Saturday, December 24th 2005 @ 12:22:26 AM
Script : http://localhost/forums/admincp/bann...activate&bid=1
Referrer :
IP Address : 127.0.0.1
Username : admin
Classname : vB_Database

I found this error? How can we fix that? plzzz

oops... my mistake... forgot to add the table prefix in some queries...
i'll just sent an update, just download and replace you /admincp/banner_rotator.php with the one in the package
that should fix your problem... if you get any other error, please report here

slvr ralliart 12-23-2005 07:51 PM

I installed your banner rotator...

I go to upload a banner and I get this error screen..

https://vborg.vbsupport.ru/external/...chmentid=39860

DS MrSinister 12-23-2005 07:59 PM

uninstall it first

you need to edit the installer file and banner_rotator file thats in admincp folder..

look for forum and change it too forums

thats should take care of your problem.

after making these changs make sure you reinstall it..

andrefedalto 12-23-2005 10:27 PM

Quote:

Originally Posted by slvr ralliart
I installed your banner rotator...

I go to upload a banner and I get this error screen..

https://vborg.vbsupport.ru/attachmen...chmentid=39860

just like sinister said..
uninstall it, open banner_rotator.php and product-brotator.xml.. you can do it with notepad..

press CTRL+H (to replace texts)
and replace "/forum" with "/forums"
save the files, reupload the .php file and reinstall the product

chmod "banners" folder to 777 and it will work perfectly

Aerovive1 12-25-2005 04:46 PM

Does this mod work? I'm a lil concerned installing it with all the errors everyone has been getting...

andrefedalto 12-25-2005 08:27 PM

Quote:

Originally Posted by Aerovive1
Does this mod work? I'm a lil concerned installing it with all the errors everyone has been getting...

'course it works.. i'm using it :)
try it out, if you get any kind of errors, contact me ;)

puertoblack2003 12-26-2005 01:07 AM

getting this error:

Invalid SQL:
INSERT INTO brotator (id, name, alt, active) VALUES ('', 'toonsalbumdecor3.gif', 'Toon's Album Decor', '1');

MySQL Error : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 's Album Decor', '1')' at line 1
Error Number : 1064
Date : Sunday, December 25th 2005 @ 07:03:36 PM
Script : http://www.xxxxxxxxx/admincp/banner_rotator.php
Referrer : http://xxxxxxxx/admincp/banner_rotator.php?do=add
IP Address : xxxxxxxxxxxx
Username : xxxxxxxxx
Classname : vb_database

Aerovive1 12-26-2005 09:10 PM

I'm getting this error when I try isntalling a banner, and why is there no field to enter a url?

Warning: move_uploaded_file(/home/toyotaug/public_html/forum/images/banners/otugbanner.gif): failed to open stream: No such file or directory in /admincp/banner_rotator.php on line 56

Warning: move_uploaded_file(): Unable to move '/tmp/php3GF8oT' to '/home/toyotaug/public_html/forum/images/banners/otugbanner.gif' in /admincp/banner_rotator.php on line 56

andrefedalto 12-26-2005 10:38 PM

Quote:

Originally Posted by nievesidenshop
getting this error:

Invalid SQL:
INSERT INTO brotator (id, name, alt, active) VALUES ('', 'toonsalbumdecor3.gif', 'Toon's Album Decor', '1');

MySQL Error : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 's Album Decor', '1')' at line 1
Error Number : 1064
Date : Sunday, December 25th 2005 @ 07:03:36 PM
Script : http://www.xxxxxxxxx/admincp/banner_rotator.php
Referrer : http://xxxxxxxx/admincp/banner_rotator.php?do=add
IP Address : xxxxxxxxxxxx
Username : xxxxxxxxx
Classname : vb_database

dont use ' in the names

andrefedalto 12-26-2005 10:39 PM

Quote:

Originally Posted by Aerovive1
I'm getting this error when I try isntalling a banner, and why is there no field to enter a url?


Warning: move_uploaded_file(/home/toyotaug/public_html/forum/images/banners/otugbanner.gif): failed to open stream: No such file or directory in /admincp/banner_rotator.php on line 56

Warning: move_uploaded_file(): Unable to move '/tmp/php3GF8oT' to '/home/toyotaug/public_html/forum/images/banners/otugbanner.gif' in /admincp/banner_rotator.php on line 56

uninstall it, open banner_rotator.php and product-brotator.xml.. you can do it with notepad..

press CTRL+H (to replace texts)
and replace "/forum" with "/PATH"
(where PATH is the path name where your forum is located into)
save the files, reupload the .php file and reinstall the product

chmod "banners" folder to 777 and it will work perfectly

Aerovive1 12-26-2005 10:58 PM

Got it. Now isn't there an option to insert a URL to the individual banners?

andrefedalto 12-26-2005 11:00 PM

Quote:

Originally Posted by Aerovive1
Got it. Now isn't there an option to insert a URL to the individual banners?

what do you mean? to use banners hosted outside your host?

Aerovive1 12-26-2005 11:03 PM

I mean...when I installed this I thought it would be a banner rotator, where you can rotate different banners and specifiy a different url for each banner...

Right now it's jsut a picture rotating with no url...i want to link to different places with my banners...

andrefedalto 12-26-2005 11:05 PM

Quote:

Originally Posted by Aerovive1
I mean...when I installed this I thought it would be a banner rotator, where you can rotate different banners and specifiy a different url for each banner...

Right now it's jsut a picture rotating with no url...i want to link to different places with my banners...

to add a link to the image and another link, so when you click the image you will be redirected to the second link?

Aerovive1 12-26-2005 11:18 PM

no i just want to add a single link to each individual banner...

Right now I see no field to do this

andrefedalto 12-27-2005 12:35 AM

Quote:

Originally Posted by Aerovive1
no i just want to add a single link to each individual banner...

Right now I see no field to do this

just did an update for ya... didnt test, but i dont think anything is wrong..

added field for input link.

Just download the attachement, reupload banner_rotator.php and reinstall product-brotator.xml

that should work for you

JsnakeJ 12-27-2005 12:50 AM

This reminds me of the Banner & Ads hack for vBulletin 3.0.X, I may try it out and see if I like it.

Just wondering, does this only work in the header?

andrefedalto 12-27-2005 12:57 AM

Quote:

Originally Posted by JsnakeJ
This reminds me of the Banner & Ads hack for vBulletin 3.0.X, I may try it out and see if I like it.

Just wondering, does this only work in the header?

anywhere you put the code $banner will show up the banner ;)

JsnakeJ 12-27-2005 01:08 AM

Nifty.

* JsnakeJ clicks install.

Can you edit the one with links to allow images that you link to? I don't care for it uploading them to my server much.

andrefedalto 12-27-2005 01:30 AM

Quote:

Originally Posted by JsnakeJ
Nifty.

* JsnakeJ clicks install.

Can you edit the one with links to allow images that you link to? I don't care for it uploading them to my server much.

also didnt tested.
This one allows you to insert a link instead of uploading the banner in your host.

Try it out and tell us if works :)

JsnakeJ 12-27-2005 01:58 AM

Few things need fixed.

Change it to 'Link to Banner'.
Add size forms and remove the part to automatically make it header sized.

Other than that it works perfect.


All times are GMT. The time now is 09:37 PM.

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.01561 seconds
  • Memory Usage 1,829KB
  • 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
  • (3)bbcode_code_printable
  • (12)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete