vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Graveyard (https://vborg.vbsupport.ru/forumdisplay.php?f=224)
-   -   Miscellaneous Hacks - Rotational Banner in Header (https://vborg.vbsupport.ru/showthread.php?t=98913)

HMBeaty 10-20-2005 10:00 PM

Rotational Banner in Header
 
Well, I KNOW alot of you are looking for this as I was so here it is......

Also, found this on vBulletin.com, so ALL credit goes to "express" for this one. :) (I just modified it a little)

Go to AdminCP > Styles and Templates> Style Manager > YOUR TEMPLATE > header

In that, find.....

Code:

        <td align="$stylevar[left]"><a href="$vboptions[forumhome].php$session[sessionurl_q]"><img src="$stylevar[titleimage]" border="0" alt="$vboptions[bbtitle]" /></a></td>
Under that, add.....

Code:

<SCRIPT LANGUAGE="Javascript"><!--

// ***********************************************
// AUTHOR: <a href="http://WWW.CGISCRIPT.NET," target="_blank">WWW.CGISCRIPT.NET,</a> LLC
// URL: <a href="http://www.cgiscript.net" target="_blank">http://www.cgiscript.net</a>
// Use the script, just leave this message intact.
// Download your FREE CGI/Perl Scripts today!
// ( <a href="http://www.cgiscript.net/scripts.htm" target="_blank">http://www.cgiscript.net/scripts.htm</a> )
// ***********************************************

function banner() {
};

banner = new banner();
number = 0;

// bannerArray
banner[number++] = "<a href='REDIRECT URL' target='_blank'><img src='BANNER IMAGE' border='1'></a>"
banner[number++] = "<a href='REDIRECT URL' target='_blank'><img src='BANNER IMAGE' border='1'></a>"
banner[number++] = "<a href='REDIRECT URL' target='_blank'><img src='BANNER IMAGE' border='1'></a>"
 
// keep adding items here...

increment = Math.floor(Math.random() * number);

document.write(banner[increment]);

//--></SCRIPT>


Save and you're done

HMBeaty 10-21-2005 02:19 AM

Sorry, this is probably supposed to go in template modifications if someone can move it please.

:Judge: 10-21-2005 02:56 AM

Very nice, thank you much!

HMBeaty 10-21-2005 02:58 AM

You are very welcome. You can't imagine how happy I was when I found this after searching for something like this for 6 weeks

mholtum 10-21-2005 03:16 AM

hmm. A simple image rotator? And?????

:Judge: 10-21-2005 03:54 AM

Quote:

Originally Posted by mholtum
hmm. A simple image rotator? And?????

Makes it a little easier to find for people such as myself without the time to search all over the place looking for something.

Snake 10-21-2005 10:02 AM

Nice, thanks and installed! :)

TygerTyger 10-21-2005 02:09 PM

I don't mean to rain on anyone's parade :( but this image rotator requries javascript to be enabled in the user's browser. The hack below does exactly the same thing but does not.

https://vborg.vbsupport.ru/showthread.php?t=94433

I like the stylistic idea though, I did exactly the same thing on my own forum and removed the bbtitle to make way for the banner. Looks very cool :D

Nuckolsc.com 10-21-2005 02:45 PM

Thanks man... Ive been looking for a simple banner mod for my sponsors. Installed

Jenkins 10-21-2005 09:28 PM

Quote:

Originally Posted by TygerTyger
I don't mean to rain on anyone's parade :( but this image rotator requries javascript to be enabled in the user's browser. The hack below does exactly the same thing but does not.

https://vborg.vbsupport.ru/showthread.php?t=94433

I like the stylistic idea though, I did exactly the same thing on my own forum and removed the bbtitle to make way for the banner. Looks very cool :D

This one allows you to make the Picture a link. I don't see where the one you pointed out does that.


All times are GMT. The time now is 08:34 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.01185 seconds
  • Memory Usage 1,736KB
  • 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
  • (2)bbcode_code_printable
  • (2)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
  • (10)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