• Fotography 2.1.3
    With plugin “sunshine-photo-cart” I get following error:
    Fatal error: Cannot redeclare tgmpa() (previously declared in /homepages/4/d617132940/htdocs/clickandbuilds/fotografiepb/wp-content/plugins/sunshine-photo-cart/addons/addon-manager/class-tgm-plugin-activation.php:2126) in /homepages/4/d617132940/htdocs/clickandbuilds/fotografiepb/wp-content/themes/fotography/inc/fotography-plugin-activation.php on line 2124

    Checked fotography-plugin-activation.php on line 2114
    if ( ! function_exists( ‘fotography’ ) ) {

    changed to:
    if ( ! function_exists( ‘tgmpa’ ) ) {

    and it worked again. Don’t know if this is correct? Please give some advice. Thanks.

Viewing 1 replies (of 1 total)
  • Hi @silversunny,

    That’s completely correct. The fotography theme contained a search & replace error which you just corrected ??

    You may also want to check the version of the TGMPA library – it should be 2.6.1 which is the current version. If it is not, you may want to consider upgrading it by downloading the newer version & just drop-in replacing the old one with it.

    If it is a theme which is distributed, I would advise you to contact the theme author to get the error corrected in the theme itself (and to upgrade!) as otherwise you may run into the same issue when upgrading the next time (and it might save some other people a headache too).

    Pro-tip for the theme author: If they download a fresh copy of TGMPA using the [https://tgmpluginactivation.com/download/ Custom TGMPA Generator], it will serve them with a customized download of TGMPA which will pass the Theme Check rules (text-domain and such), so they don’t have to do any search & replace themselves anymore.

    Smile,
    Juliette

Viewing 1 replies (of 1 total)
  • The topic ‘Fatal error: Cannot redeclare tgmpa()’ is closed to new replies.