I found a solution! Feel so proud of myself hahaha.
This is how i do it in case some1 is interested:
a) create all the images (same height and width, any names) and put them in /img/headers/
b) Create this php file (random_image.php) and put in in my /style/ directory
<?php
header('Content-type: text/css');
$dir=opendir("/data/4/0/51/132/214947/user/218384/htdocs/kadus/img/headers/"); // actual path of the images to select
$pattern="\.(gif|jpg|jpeg|png|bmp|swf)$";
if(!$dir)
{
die("Failed to read directory");
}
$s=readdir($dir);
$count="0";
$image;
while($s)
{
if(ereg($pattern, $s))
{
$image[$count]=$s;
$count++;
}
$s=readdir($dir);
}
closedir($dir);
// make random number
$limit=count($image);
$limit--;
$randNum=rand(0,$limit);
?>
.pun #brdtitle h1 span{
/* remove slash and* for hidden title
font-size: 0;
text-indent: -1000px;
*/
/* use this if the title is not hidden */
padding-top: 40px;
padding-left: 5px;
padding-bottom:0px;
color: #FFF;
/* */
display:block;
height: 160px;
/* change the height above to fit your actual header img height */
background-image: url(<?="http://your forum.coc/img/headers/".$image[$randNum]; ?>);
background-position: 50% 0;
background-repeat: no-repeat;
margin-left: -5px;
margin-right: -5px;
margin-bottom: -43px;
}
In this case, I am using Blue_Lagon.cs. The style above are taken from the blue_lagon_cs.css in the /style/imports/ folder. Therefore, the original entry for the above in the blue_lagon_cs.css should be deleted.
c) open /style/blue_lagon.css and add this somewhere around the top, below the other @import statements
@import url(random_image.php);
Thats's it! The same can be applied to all the other stylesheets that you are using.