vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Banner ad on forum Home (https://vborg.vbsupport.ru/showthread.php?t=63994)

Beermonster 04-16-2004 10:00 PM

Banner ad on forum Home
 
Adapted from "Add a banner image to each forum" script by Harrybutt
https://vborg.vbsupport.ru/showthread.php?t=61555

This modification will add an image banner with link and text to each forum you choose, and display it in on your forumhome, you can have a different banner for each forum with additional text above the banner like Sponsored by or affiliated with, or you can choose to have no text.

I have used 100x25px images for the example screen shot, but you can use what ever size you like, but remember it will effect the way your forum looks.

Hope people find this usful, this is my first hack as I'm still a big noob when it come's to hacking :)

Opps sorry made a slight error in the dir name, it's fixed now :)


For 3.5.x look here

Logik 04-17-2004 03:24 PM

Nice little hack...Could be used.

poetic 04-17-2004 04:57 PM

Nice, I like this. :)

synwave 04-17-2004 07:56 PM

Excellent...I've been waiting for this!

Thanks :)

Sketch 04-19-2004 01:41 PM

Can you HTL it, please? ;) If you do I'll install it.

Aaron

synwave 04-19-2004 01:46 PM

Excuse my ignorance guys.....but what is HTL?

Cheers,
Synwave

Beermonster 04-19-2004 01:53 PM

Quote:

Originally Posted by synwave
Excuse my ignorance guys.....but what is HTL?


Cheers,
Synwave

hack Tracking Log
https://vborg.vbsupport.ru/showthrea...&highlight=HTL

I would if I could but like I said I'm a total noob at this, I will have a look in to it and see if I can :)

Sketch 04-19-2004 03:53 PM

I'll try and convert it for you. I need the practice.

Aaron

Beermonster 04-19-2004 03:55 PM

Quote:

Originally Posted by Sketch
I'll try and convert it for you. I need the practice.

Aaron

Go for it :) I don't have HTL installed, so I've never played with it.

Sketch 04-19-2004 04:49 PM

Almost there. Inquiring about some roadblocks I'm running into but hopefully something soon. You should check the HTL. It's great. I'm only installing hacks using it and my goal is to use it to write hacks (though this is the first one I'm trying to put into HTL as if I'm writing it)...

Aaron

webrats 05-04-2004 03:36 AM

would be cool if we could have both hack on the same admin page say small banner for forum home
and big banner for top of forums

Beermonster 05-04-2004 05:33 AM

Quote:

Originally Posted by webrats
would be cool if we could have both hack on the same admin page say small banner for forum home
and big banner for top of forums


You can all you need to do is install them both ;)

hooolala 05-06-2004 06:16 AM

what does add field to forum table means?

Beermonster 05-06-2004 07:43 AM

Quote:

Originally Posted by hooolala
what does add field to forum table means?

You need to go to phpmyadmin and Run SQL query/queries on database just paste this code in the box and press "go"

Code:

ALTER TABLE `forum` ADD `fhbanner` VARCHAR( 50 ) NOT NULL AFTER `description` ;
ALTER TABLE `forum` ADD `fhbannerlink` VARCHAR( 250 ) NOT NULL AFTER `fhbanner` ;
ALTER TABLE `forum` ADD `fhmessage` VARCHAR( 50 ) NOT NULL AFTER `fhbannerlink` ;


sneakyc2e 05-30-2004 03:27 PM

I did the banner hack and checked it three times to make sure I did every thing right and the banner is not showing up. Everything shows up in the user cp fine. This is the first time I have run a sql query but I went back to phpmyadmin and they show in there.

Any ideas. I really need this hack and it looks awesome in your screenshots.

I am on vBulletin Version 3.0.1

Thanks,
Dan

Beermonster 05-31-2004 12:40 PM

Quote:

Originally Posted by sneakyc2e
I did the banner hack and checked it three times to make sure I did every thing right and the banner is not showing up. Everything shows up in the user cp fine. This is the first time I have run a sql query but I went back to phpmyadmin and they show in there.

Any ideas. I really need this hack and it looks awesome in your screenshots.

I am on vBulletin Version 3.0.1

Thanks,
Dan

I've sent you a pm, not sure what could be wrong, AFAIK no one else has had problems

sneakyc2e 06-02-2004 02:10 AM

Any ideas?

paul_r 06-04-2004 09:25 AM

just ran the query and heres what i got

An error occurred while attempting to execute your query. The following information was returned.
error number: 1064
error desc: You have an error in your SQL syntax near ';
ALTER TABLE `forum` ADD `fhbannerlink` VARCHAR( 250 ) NOT NULL AFTER `fhbanne' at line 1

any ideas ? :ermm: :surprised:

Beermonster 06-04-2004 09:51 AM

I don't think you've pasted it in right, if you look at it it says "NOT NULL AFTER `fhbanne' " it should be fhbanner

paul_r 06-04-2004 10:01 AM

i dont think so m8

here the query error window copied and pasted ;)



Query
ALTER TABLE `forum` ADD `fhbanner` VARCHAR( 50 ) NOT NULL AFTER `description` ;
ALTER TABLE `forum` ADD `fhbannerlink` VARCHAR( 250 ) NOT NULL AFTER `fhbanner` ;
ALTER TABLE `forum` ADD `fhmessage` VARCHAR( 50 ) NOT NULL AFTER `fhbannerlink`



vBulletin Message
An error occurred while attempting to execute your query. The following information was returned.
error number: 1064
error desc: You have an error in your SQL syntax near ';
ALTER TABLE `forum` ADD `fhbannerlink` VARCHAR( 250 ) NOT NULL AFTER `fhbanne' at line 1

Beermonster 06-04-2004 10:43 AM

Quote:

Originally Posted by paul_r
i dont think so m8

here the query error window copied and pasted ;)



Query
ALTER TABLE `forum` ADD `fhbanner` VARCHAR( 50 ) NOT NULL AFTER `description` ;
ALTER TABLE `forum` ADD `fhbannerlink` VARCHAR( 250 ) NOT NULL AFTER `fhbanner` ;
ALTER TABLE `forum` ADD `fhmessage` VARCHAR( 50 ) NOT NULL AFTER `fhbannerlink`



vBulletin Message
An error occurred while attempting to execute your query. The following information was returned.
error number: 1064
error desc: You have an error in your SQL syntax near ';
ALTER TABLE `forum` ADD `fhbannerlink` VARCHAR( 250 ) NOT NULL AFTER `fhbanne' at line 1


There's no ; at the end of the last line, it should be
ALTER TABLE `forum` ADD `fhbanner` VARCHAR( 50 ) NOT NULL AFTER `description` ;
ALTER TABLE `forum` ADD `fhbannerlink` VARCHAR( 250 ) NOT NULL AFTER `fhbanner` ;
ALTER TABLE `forum` ADD `fhmessage` VARCHAR( 50 ) NOT NULL AFTER `fhbannerlink` ;

but you are still missing the r in the error, try deleting fhbanner, fhbannerlink & fhmessage tables and run the query again, are you using phpmyadmin or admincp? also did you do a standard install of vb? or did you give the tables a prefix?

paul_r 06-04-2004 11:26 AM

ahh forund the problem in myphp

forum didnt exist so i had to change it to vb3_forum

workes a treat

thanks

www.mx5roadsters.com/forums

:D

Beermonster 06-04-2004 01:46 PM

Quote:

Originally Posted by paul_r
ahh forund the problem in myphp

forum didnt exist so i had to change it to vb3_forum

workes a treat

thanks

www.mx5roadsters.com/forums

:D


np glad you got it working, feel free to click install ;)

sneakyc2e 06-04-2004 08:01 PM

Sent you a pm.

Dan

sneakyc2e 06-04-2004 10:09 PM

file uploaded.

Dan

sneakyc2e 06-05-2004 04:21 PM

Pmed ya again.
Thanks,
Dan

sneakyc2e 06-06-2004 08:59 PM

Thanks for going way beyond supporting me on this one bro. Clicking Install.

Dan

Jpax 06-20-2004 12:58 AM

I installed everything and checked over all the lines, i get absoulty nothing that comes up. i can see the feilds were i can add the links and text but when i add them nothing happens. Right now i am using a dev folder so the url for the images are /dev/html/forum/admincp/images/fhbanner/ssbanner.gif
but i can see the pic but if i put it in the url what am i doing wrong? :ermm:

Jpax 06-20-2004 01:52 AM

never mind im an idiot, you have to lok in the admin pannel to add the files and links. GezzUuZZz this is awesome!

sam 06-21-2004 08:35 AM

Quote:

Add these phrases:

Varname:
fhbanner

text:
Postbits Banner Image<br>(Places a image on your forum postbits) EX: banner.jpg

Varname:
fhbannerlink

text:
Postbits Banner Image Link<br>(http://www.yoursite.com)

Varname:
fhmessage

text:
Postbits Banner text i.e. Sponsored By or Affiliate with
Where i should put those phases and HOW?

any help please?

Beermonster 06-27-2004 06:10 AM

Quote:

Originally Posted by sam
Where i should put those phases and HOW?

any help please?

Go to AdminCP then Languages & Phrases/phrase manager, then add new phrase

RichieBoy67 07-02-2004 03:10 PM

Can you use google adsence with this somehow???

Beermonster 07-02-2004 05:45 PM

Quote:

Originally Posted by RichieBoy67
Can you use google adsence with this somehow???

I'm sure it could be modified to retrieve HTML files rather that pictures, but I'm not sure about using both together, after all you only usually have one Google ad account.

RichieBoy67 07-02-2004 05:53 PM

I do have only one google ad account but I use the ad code on all my sites. Seems to work.. I would like to use google ad sence buttons. I think they would fit perfectly.

How hard would it be to mod this???

Thanks

Beermonster 07-02-2004 07:00 PM

Sorry I was thinking I was replying to my rotating banner mod, it's been a long day :surprised:

I will have a look at it for you see what I can do :)

RichieBoy67 07-02-2004 07:06 PM

No Problem..lol

Thanks so much for helping! :)

Great Hack BTW

Crinos 07-03-2004 06:34 AM

Quote:

Originally Posted by RichieBoy67
I do have only one google ad account but I use the ad code on all my sites. Seems to work.. I would like to use google ad sence buttons. I think they would fit perfectly.

Doesn't the Adsense TOS specifically state that there can be only one instance of their ads per page?

RichieBoy67 07-03-2004 12:46 PM

I'm not really sure but why would they care? When ever somebody clicks they are making much more than us???

Unfortunatly I do not have any paid advertisers yet other than Google...

veedee 07-13-2004 10:33 PM

Good hack but I get this message when I try to add a banner to my main forum.

Database error in vBulletin 3.0.3:

Invalid SQL: UPDATE forum SET

### UPDATE QUERY GENERATED BY fetch_query_sql() ###
title = 'General',
description = 'Post general bike related questions, and join in the banter!',
fhbanner = 'test.jpg',
fhbannerlink = '',
fhmessage = '',
link = '',
displayorder = '1',
daysprune = '1',
parentid = '24',
newpostemail = '',
newthreademail = '',
styleid = '0',
password = '',
options = '97991',
parentlist = '1,24,-1'
WHERE forumid=1
mysql error: Unknown column 'fhbanner' in 'field list'

mysql error number: 1054

Beermonster 07-14-2004 05:37 AM

Check your mysql table it looks like you don't have fhbanner in it, also do your forum tables have a prefix on them?


All times are GMT. The time now is 05:24 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.01354 seconds
  • Memory Usage 1,818KB
  • 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
  • (11)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