vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Automatic vB logo rotation (https://vborg.vbsupport.ru/showthread.php?t=98073)

AndyA 10-10-2005 07:52 PM

Automatic vB logo rotation
 
I have a Motorcycle forum and from time to time I use one of the members ride photo's as the forum logo. Can anyone create a mod which will rotate the logo automatically say once a week ?

Thanks.

TygerTyger 10-10-2005 08:37 PM

This could easily be done with a standard php script and an include where the image graphic would go.

AndyA 10-10-2005 08:51 PM

That sounds promising, can anyone make such a script for me to use ? :nervous:

PennylessZ28 10-10-2005 09:06 PM

They are everywhere on the internet.

Your image code:
Code:

<img src="$headerimage" border="0" alt="$vboptions[bbtitle]" />
Put this in your phpinclude_start
Code:

$totalheaderimages = X; // change to the number of header images you have
$randomindex = rand(1, $totalheaderimages);
$headerimage = "images/random/header$randomindex.gif"; // change to the path of your images

You would images header01 header02 etc

AndyA 10-10-2005 09:24 PM

I'm not that familiar with php stuff, can you explain in dummy speak ?

My header:-

Code:

<!-- logo -->
<a name="top"></a>
<table border="0" width="$stylevar[outertablewidth]" cellpadding="0" cellspacing="0" align="center">
<tr>
        <td align="center"><a href="http://www.throttlejockey.co.uk/cmps_index.php"><img src="$stylevar[titleimage]" border="0" alt="$vboptions[bbtitle]" /></a></td>

</tr>
</table>
<!-- /logo -->

<!-- content table -->
$spacer_open

$_phpinclude_output

Also where would I find phpinclude_start (I use vB 3.5).

Much appreciated.

Anyone ?

XFGHIA 10-16-2005 04:03 AM

I also cannot find phpinclude_start template in vb 3.5

GottaBeKD 10-16-2005 04:55 PM

You probably can't find it, because it doesn't exist ;)

Instead (for 3.5), go to "Plugin System -> Add New Plugin". Select "global_start" for the location, and give it a title. In this case, something like "Logo Rotation".

Then, put the php code in the "code" box.


All times are GMT. The time now is 03:05 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.00986 seconds
  • Memory Usage 1,717KB
  • 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
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (7)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete