Support » Plugin: Loco Translate » Error: Editing files is blocked by your WordPress configuration

  • Resolved alessandro986

    (@alessandro986)


    hi, when I try to update the translations, the following messages appear:

    Notice: Unable to create a backup file under “themes”. Check file permissions or disable backups
    Error: Editing files is blocked by your WordPress configuration

    it’s like there is a blockage. How can I proceed? can someone help me?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Tim W

    (@timwhitlock)

    Editing files is blocked by your WordPress configuration

    The original message in English is “File modification is disallowed by your WordPress config”. Assuming that we’re discussing the same message – This appears when your site is deliberately preventing updates to a file.

    Loco Translate honours the result returned from wp_is_file_mod_allowed. To fix it, you should speak to whoever has decided this should be disallowed. If that person is you, then look at the documentation for wp_is_file_mod_allowed and look at the code that calls it.

    This may be as simple as disabling DISALLOW_FILE_MODS but it may be more complex. I can’t tell you about your site.

    Loco Translate calls wp_is_file_mod_allowed with the same context that WordPress does when it attempts to update an installed translation file (download_language_pack). That context can be modified with the filter loco_file_mod_allowed_context as shown in the code link above.

    Plugin Author Tim W

    (@timwhitlock)

    I’ve added a section in the manual with this information.

    I am marking as resolved as I feel the question is answered as far as I can answer it.

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.