0

How can I init ezcMail in my php application? I am planning to use this to create raw email messages to be used int he Gmail API. I have the required extensions: SPL and iconv. This has been giving me allot of trouble! I finally got it to load by doing this:

require _SITE_ROOT_.'core/class/ezc/'.'Base/src/options.php';
require _SITE_ROOT_.'core/class/ezc/'.'Base/src/struct.php';
require _SITE_ROOT_.'core/class/ezc/'.'Base/src/structs/repository_directory.php';
require _SITE_ROOT_.'core/class/ezc/'.'Base/src/ezc_bootstrap.php';
spl_autoload_register( array( 'ezcBase', 'autoload' ) );

There must be a better way... Am I doing this wrong?

Ruttyj
  • 853
  • 2
  • 11
  • 18

1 Answers1

1

I would recommend that you install the zeta components library using the package manager composer. It includes an autoloader that will pull in the required classes.

johncorser
  • 9,262
  • 17
  • 57
  • 102