Viewing 1 replies (of 1 total)
  • Plugin Author wpsolutions

    (@wpsolutions)

    Hi,

    Is there a way to check whether the class is declared, and activate accordingly?

    I’m using a PHP wrapper library for the MailChimp API and am checking if the main library class is already declared – if it is I do not load the file.

    This would also be a great question to ask of the developer of the “Easy Maichimp Forms plugin” too ??

    For instance I would ask them if they could apply some checks inside the following file of their plugin:
    classes\MCAPI_2.0.class.php

    See below for example code of the types of checks I mean:

    if (!class_exists('Mailchimp_Folders')) {
    	require_once YKSEME_PATH.'/Mailchimp/Folders.php';
    }
    
    if (!class_exists('Mailchimp_Templates')) {
    	require_once YKSEME_PATH.'/Mailchimp/Templates.php';
    }
    
    if (!class_exists('Mailchimp_Users')) {
    	require_once YKSEME_PATH.'/Mailchimp/Users.php';
    }
    ......
    etc

    The above checks will prevent an error such as the one you are seeing.

Viewing 1 replies (of 1 total)
  • The topic ‘Fatal error: can not create folder’ is closed to new replies.