• Resolved castalina

    (@castalina)


    I installed a child theme to my site, via the Childify Me plug in, and copied in some code in the the child theme function php file – a code to change the footer credits fron “Designed by…” to my own text. I have previouslu put this in the parent themes functions php file, but then I need to put it back each time I upgrade the theme. Thought it would be easier to put it in the child themes function php file…

    Got this message, and now I can’t get in to the site at all!:

    Fatal error: Cannot redeclare my_custom_credits() (previously declared in /storage/content/84/124384/test.mindgarden.se/public_html/wp-content/themes/child-customizr/functions.php:6) in /storage/content/84/124384/test.mindgarden.se/public_html/wp-content/themes/customizr/functions.php on line 61

    What do I do??

Viewing 5 replies - 1 through 5 (of 5 total)
  • Seems like you added the function my_custom_credits() in child-customizr/functions.php and customizr/functions.php.
    Remove the function in customizr/functions.php and it should work again.

    Thread Starter castalina

    (@castalina)

    Thanks. I couldn’t get out of the page, and couldn’t log out, so finally I closed the browser hoping I could get back in. Now I can’t even get in to the login page, all I see is the above Fatal error message on the top of the page when I use my bookmark/or type in https://www.test.mindgarden.se/wp-login.php … How do I get back in to the wp-login page??

    Connect to your site’s files using an FTP client (for example FileZilla) or your host’s file manager (if available), navigate to /wp-content/themes/customizr, open the functions.php and remove the my_custom_credits() function.

    Thread Starter castalina

    (@castalina)

    Thank you! Could reach my server host now and get som help with the FTP settings, there had been an update on their side and then I could do the changes you suggested. Problem solved, phew!

    Glad you where able to solve the problem.

    For future changes on your child-themes functions.php:
    Download a copy of it before doing any changes ??
    The problem may occur again, as soon as you use a functionname twice, miss some brackets or another minor error.
    In that case, just overwrite the faulty functions.php with your copy through ftp.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Fatal error! functions php’ is closed to new replies.