The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
rotating header help
Ok , i have tryed the tutorials i have found here on how to make my header rotate but they didn`t work . On my website i have an php script that rotates my headers, i have 6 .
The code is : Code:
<?php $total = "6"; $file_type = ".jpg"; $image_folder = "images/headers"; $start = "1"; $random = mt_rand($start, $total); $image_name = $random . $file_type; echo "<td background=\"$image_folder/$image_name\" /></td>"; ?> Code:
<TABLE bgcolor="#eeeeee" width="702" height="228" align="center" cellpadding="0" cellspacing="0" style="border-left: 3px #707070 solid; border-right: 3px #707070 solid;"> <TR> <?php include('random-header.php'); ?> </TR> </TABLE> Thanks in advance , Iulian |
#2
|
||||
|
||||
You can't put php in the templates, You'll need to add your code to a plugin, and then call it from there.
Here is a easy way to do it, http://www.vbulletin.com/forum/showthread.php?t=170826 |
#3
|
|||
|
|||
uhm, yeah i have tryed that but still not showing the images
|
#4
|
|||
|
|||
Try using an iframe that calls for the php file. I did that for my banner rotator on my site, and it works fine. You can use php in vb, just have to be tricky about how you do it =)
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|