I have created a simple child theme of Twenty Eleven, with a style.css, a functions.php and a footer.php
The functions.php is the following:
<?php
//This adds a custom favicon to the front site of the website
function childtheme_favicon() { ?>
<link rel="shortcut icon" href="<?php echo
bloginfo('stylesheet_directory') ?>/images/favicon.ico">
<?php }
add_action('wp_head', 'childtheme_favicon');
//This is for automatically calculating the copyright years
function comicpress_copyright() {
global $wpdb;
$copyright_dates = $wpdb->get_results("SELECT
YEAR(min(post_date_gmt)) AS firstdate,
YEAR(max(post_date_gmt)) AS lastdate FROM $wpdb->posts
WHERE post_status = 'publish' ");
$output = '';
if($copyright_dates) {
$copyright = "© " . $copyright_dates[0]->firstdate;
if($copyright_dates[0]->firstdate != $copyright_dates[0]->lastdate) {
$copyright .= '-' . $copyright_dates[0]->lastdate;
}
$output = $copyright;
}
return $output;
}
?>
The footer.php used to have some code for copyrights, but as of now, for testing reasons it is an exact copy of the unedited parent theme.
WSOD [aka the White Screen of Death]
So here is the problem. If I remove either the footer.php or the functions.php from the child theme, the site works as expected!
But if those two coexist in the child-theme folder, I get a completely blank screen when I try to logout. If i force logging out by deleting cookies, salt or whatever, I cannot log back in the dashboard, getting a blank screen once again. Tried different browsers with the same results, and debugging mode is active but I got no error messages so far. The site is hosted on bluehost.
Any ideas, please?