• Thanks in advance for your help.

    I manage several websites and I suddenly have 3 that are giving me the white screen on the login page – the sites are functioning just fine on the front end.

    I have narrowed the issue down to the theme for all 3 sites. If I re-name the theme folder via FTP I can access each login area and view my dashboard. I did this for each of the 3 sites, then completed any updates and put the theme name back as it was so that the site will look and function correctly again, on the front end.

    2 of the sites are using “Twenty Sixteen” child themes and the other is using a child theme of “Athena.”

    Prior to this discovery, I had added google analytics into the functions.php file of all my wordpress sites as described in this article: https://www.hermesthemes.com/add-google-analytics-wordpress-website/

    What should my next step be? Thanks again.

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Use this code to add you google analytics

    <?php
    
    add_action( 'wp_head', 'google_analytics_script' );
    
    function google_analytics_script() {
    ?>
    <script>/* YOUR GOOGLE ANALYTICS SCRIPT */</script>
    <?php
    }
    
    ?>
    Thread Starter Image Works, Inc.

    (@nimage)

    Hmmmm. That didn’t take. Great suggestion though.

    Any other ideas?

    Thread Starter Image Works, Inc.

    (@nimage)

    Maybe this will be helpful:

    If I change the name of the theme folder, I can log in to wordpress. I can then change the name of the theme folder back to its correct name and continue to work in wordpress, but the moment I click “update” on a page, I get the white screen.

    Thread Starter Image Works, Inc.

    (@nimage)

    Ok, it seems that I have fixed the issue. The bottom line is that when I added the PHP function for google analytics into functions.php in my child theme, I had a syntax error.

    At the end of the function that enqueues the parent style, there is a closing PHP tag.

    The next function that I added (via copy & paste) contained opening and closing PHP tags as well. There needed to be only 1 opening and 1 closing PHP tag on the document, so I removed the closing tag from the 1st function and the opening tag from the 2nd and now I’m back to normal with functioning styles and google analytics.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘White screen on login only’ is closed to new replies.