Rotate images in header based on date

The following code will cycle between the 9 pics. 1st day of the year = pic0, 2nd = pic1…359th = pic9, 360th = pic0, etc.

<?php
$pic_array = array(
    'pic0',
    'pic1',
    'pic2',
    'pic3',
    'pic4',
    'pic5',
    'pic6',
    'pic7',
    'pic8',
);

$d = (int) date('z') % 9;
$todays_pic = $pic_array[$d];
echo $todays_pic;

Hopefully you’re not changing a parent theme’s header.php!