I recommend you register a post type called ‘header_slide’ and use the featured image of said posts as the banner. Do a query with a maximum of 1 post per page and display the banner, and add the url as a custom field.
Something similar to this:
$q = new WP_Query(array(
'post_type' => 'header_slide',
'posts_per_page' => 1,
'orderby ' => 'rand'
));
if($q->have_posts()){
while($q->have_posts()){
$q->the_post();
if(has_post_thumbnail()){
$url = get_post_meta($post->ID,'custom_header_link',true);
if(empty($url)){
$url = home_url();
}
echo '<a href="'.$url.'">';
the_post_thumbnail(array(920,200)); // adjust numbers to fit desired size
echo '</a>';
}
}
} else {
// hmm no header slides were found, ABORT!!!!!! or maybe display a default
}
wp_reset_postdata();
To generate the code for registering the header_slide
post type, go here:
http://themergency.com/generators/wordpress-custom-post-types/
Answer the questions and it will generate a chunk of code for you at the end, put that code into your themes functions.php, and make sure it supports custom fields and featured images/post thumbnails