Search code examples
phpemailpear

Pear Mail corrupting php file


When I try to include PEAR's Mail.php, it breaks my code.

I have installed PEAR properly (followed the instructions on the PEAR site and received proper output code) and added an include_path in the php.ini to PEAR for when I need to include the package. Basically all instructions on how to install properly were followed to a T.

Why would including PEAR's Mail.php break my code unrelated to PEAR? Even when I have nothing pertaining to PEAR's Mail.php besides the include (or require_once), my other code breaks.


Solution

  • There is probably a variable/object conflict of some kind. You might be redefining something unintentionally that has already been defined in the PEAR Mail include. Without seeing the code it is hard to say.