Okay
  Public Ticket #2329962
Functions.php not getting updated
Closed

Comments

  •  2
    Aarooran17 started the conversation

    Hi!

    We've been trying to insert some code into the functions.php file for various functions, the most recent being to get a shortcode working within an html-coded, 3rd party widget. But whenever we have done so, the code does not update into the file and we receive the following error:


    Unable to communicate back with site to check for fatal errors, so the php change was reverted. You will need to upload your php file change by some other means, such as by using sftp.


    Although it may work, I do not wish to use SFTP to push my code in. Could you give me a solution to the problem, please? I have attached the functions.php code file below.

  •  1,603
    Barry replied

    Hi there,

    Please note that it is recommend to use the child theme for making changes directly to the template files. Changes you make directly to the template files of the parent theme will be overwritten on updating the theme.

    I'm not sure if this error is a security restriction set by your hosting provider or that the issue is caused due to the closing PHP tag at the bottom of the functions.php file.  Can you first try to remove the "?>" tag at the bottom to see if that will fix the issue?

    If note, there is no other option to make changes to this file by logging in to your server by FTP.

    Best regards,
    Barry
    QreativeThemes.com  |  WordPress Themes