Skip to content
This repository has been archived by the owner on Mar 28, 2018. It is now read-only.

Commit

Permalink
1.4.1
Browse files Browse the repository at this point in the history
PHPMailer 5.2.10
  • Loading branch information
Bizley committed May 4, 2015
1 parent 3730f5d commit 10f3a6b
Show file tree
Hide file tree
Showing 133 changed files with 2,640 additions and 1,963 deletions.
18 changes: 9 additions & 9 deletions MultiMailer/MultiMailer.php
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
<?php
/**
* @author Paweł Bizley Brzozowski
* @version 1.4
* @version 1.4.1
* @license http://opensource.org/licenses/bsd-license.php
*
* MultiMailer is the Yii extension created to send or store emails in database
* with the help of the amazing PHPMailer class.
* @see https://github.com/bizley-code/Yii-MultiMailer
* @see http://www.yiiframework.com/extension/multimailer
* https://github.com/bizley-code/Yii-MultiMailer
* http://www.yiiframework.com/extension/multimailer
*
* See Examples folder for configuration and usage examples.
*
* MultiMailer requires Yii version 1.1.
* @see http://www.yiiframework.com
* @see https://github.com/yiisoft/yii
* http://www.yiiframework.com
* https://github.com/yiisoft/yii
*
* MultiMailer 1.4 uses PHPMailer version 5.2.9
* @see https://github.com/PHPMailer/PHPMailer
* MultiMailer 1.4.1 uses PHPMailer version 5.2.10
* https://github.com/PHPMailer/PHPMailer
*
* Available methods:
* mail()
Expand All @@ -28,7 +28,7 @@
* database storage
*/

require_once \dirname(__FILE__) . DIRECTORY_SEPARATOR . 'PHPMailer-5.2.9' . DIRECTORY_SEPARATOR . 'PHPMailerAutoload.php';
require_once \dirname(__FILE__) . DIRECTORY_SEPARATOR . 'PHPMailer-5.2.10' . DIRECTORY_SEPARATOR . 'PHPMailerAutoload.php';

class MultiMailer extends CApplicationComponent
{
Expand Down Expand Up @@ -477,7 +477,7 @@ protected function _initGMAIL()
/**
* Initialises the MAIL method.
* Emails are sent using mail() function.
* @see http://php.net/manual/en/function.mail.php
* http://php.net/manual/en/function.mail.php
* This is the default method.
* @return boolean
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
docs/phpdoc/
test/message.txt
test/testbootstrap.php
test/*.pem
.idea
build/
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
build:
environment:
php: '5.6.0'

before_commands:
- "composer install --prefer-source"

tools:
# Code Coverage
external_code_coverage:
enabled: true
timeout: 300
Expand All @@ -14,10 +17,8 @@ tools:
- 'test/*'
- 'vendor/*'


php_code_coverage:
enabled: false
test_command: phpunit
filter:
excluded_paths:
- 'docs/*'
Expand All @@ -26,13 +27,14 @@ tools:
- 'test/*'
- 'vendor/*'


# Code Sniffer
php_code_sniffer:
enabled: true
command: phpcs
config:
standard: PSR2
sniffs:
generic:
files:
one_class_per_file_sniff: false
filter:
excluded_paths:
- 'docs/*'
Expand All @@ -41,23 +43,19 @@ tools:
- 'test/*'
- 'vendor/*'


# Copy/Paste Detector
php_cpd:
enabled: true
command: phpcpd
excluded_dirs:
- docs
- examples
- extras
- test
- vendor


# PHP CS Fixer (http://http://cs.sensiolabs.org/).
php_cs_fixer:
enabled: true
command: php-cs-fixer
config:
level: psr2
filter:
Expand All @@ -68,29 +66,27 @@ tools:
- 'test/*'
- 'vendor/*'


# Analyzes the size and structure of a PHP project.
php_loc:
enabled: true
command: phploc
excluded_dirs:
- docs
- examples
- extras
- test
- vendor


# PHP Mess Detector (http://phpmd.org).
php_mess_detector:
enabled: true
command: phpmd
config:
rulesets:
- codesize
- unusedcode
- naming
- design
naming_rules:
short_variable: { minimum: 2 }
filter:
excluded_paths:
- 'docs/*'
Expand All @@ -99,11 +95,9 @@ tools:
- 'test/*'
- 'vendor/*'


# Analyzes the size and structure of a PHP project.
php_pdepend:
enabled: true
command: pdepend
excluded_dirs:
- docs
- examples
Expand All @@ -112,8 +106,20 @@ tools:
- vendor

# Runs Scrutinizer's PHP Analyzer Tool
# https://scrutinizer-ci.com/docs/tools/php/php-analyzer/config_reference
php_analyzer:
enabled: true
config:
checkstyle:
enabled: true
naming:
enabled: true
property_name: ^[_a-zA-Z][a-zA-Z0-9_]*$ #Allow underscores & caps
method_name: ^(?:[_a-zA-Z]|__)[a-zA-Z0-9_]*$ #Allow underscores & caps
parameter_name: ^[a-z][a-zA-Z0-9_]*$ # Allow underscores
local_variable: ^[a-zA-Z][a-zA-Z0-9_]*$ #Allow underscores & caps
exception_name: ^[a-zA-Z][a-zA-Z0-9]*Exception$
isser_method_name: ^(?:[_a-zA-Z]|__)[a-zA-Z0-9]*$ #Allow underscores & caps
filter:
excluded_paths:
- 'docs/*'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
language: php
php:
- 7.0
- 5.6
- 5.5
- 5.4
- 5.3
- hhvm

matrix:
allow_failures:
- php: hhvm
allow_failures:
- php: 7.0
- php: hhvm

before_install:
- sudo apt-get update -qq
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,18 @@ Build status: [![Build Status](https://travis-ci.org/PHPMailer/PHPMailer.svg)](h
[![Scrutinizer Quality Score](https://scrutinizer-ci.com/g/PHPMailer/PHPMailer/badges/quality-score.png?s=3758e21d279becdf847a557a56a3ed16dfec9d5d)](https://scrutinizer-ci.com/g/PHPMailer/PHPMailer/)
[![Code Coverage](https://scrutinizer-ci.com/g/PHPMailer/PHPMailer/badges/coverage.png?s=3fe6ca5fe8cd2cdf96285756e42932f7ca256962)](https://scrutinizer-ci.com/g/PHPMailer/PHPMailer/)

[![Latest Stable Version](https://poser.pugx.org/phpmailer/phpmailer/v/stable.svg)](https://packagist.org/packages/phpmailer/phpmailer) [![Total Downloads](https://poser.pugx.org/phpmailer/phpmailer/downloads)](https://packagist.org/packages/phpmailer/phpmailer) [![Latest Unstable Version](https://poser.pugx.org/phpmailer/phpmailer/v/unstable.svg)](https://packagist.org/packages/phpmailer/phpmailer) [![License](https://poser.pugx.org/phpmailer/phpmailer/license.svg)](https://packagist.org/packages/phpmailer/phpmailer)

## Class Features

- Probably the world's most popular code for sending email from PHP!
- Used by many open-source projects: Drupal, SugarCRM, Yii, Joomla! and many more
- Used by many open-source projects: Wordpress, Drupal, 1CRM, SugarCRM, Yii, Joomla! and many more
- Integrated SMTP support - send without a local mail server
- Send emails with multiple TOs, CCs, BCCs and REPLY-TOs
- Multipart/alternative emails for mail clients that do not read HTML email
- Support for UTF-8 content and 8bit, base64, binary, and quoted-printable encodings
- SMTP authentication with LOGIN, PLAIN, NTLM and CRAM-MD5 mechanisms over SSL and TLS transports
- Native language support
- Error messages in 47 languages!
- DKIM and S/MIME signing support
- Compatible with PHP 5.0 and later
- Much more!
Expand All @@ -36,14 +38,19 @@ software availability and distribution.

## Installation & loading

PHPMailer is available via [Composer/Packagist](https://packagist.org/packages/phpmailer/phpmailer). Alternatively, just copy the contents of the PHPMailer folder into somewhere that's in your PHP `include_path` setting. If you don't speak git or just want a tarball, click the 'zip' button at the top of the page in GitHub.
PHPMailer is available via [Composer/Packagist](https://packagist.org/packages/phpmailer/phpmailer), so just add this line to your `composer.json` file:

"phpmailer/phpmailer": "~5.2"

Alternatively, copy the contents of the PHPMailer folder into somewhere that's in your PHP `include_path` setting. If you don't speak git or just want a tarball, click the 'zip' button at the top of the page in GitHub.

If you're not using composer's autoloader, PHPMailer provides an SPL-compatible autoloader, and that is the preferred way of loading the library - just `require '/path/to/PHPMailerAutoload.php';` and everything should work. The autoloader does not throw errors if it can't find classes so it prepends itself to the SPL list, allowing your own (or your framework's) autoloader to catch errors. SPL autoloading was introduced in PHP 5.1.0, so if you are using a version older than that you will need to require/include each class manually.

PHPMailer provides an SPL-compatible autoloader, and that is the preferred way of loading the library - just `require '/path/to/PHPMailerAutoload.php';` and everything should work. The autoloader does not throw errors if it can't find classes so it prepends itself to the SPL list, allowing your own (or your framework's) autoloader to catch errors. SPL autoloading was introduced in PHP 5.1.0, so if you are using a version older than that you will need to require/include each class manually.
PHPMailer does *not* declare a namespace because namespaces were only introduced in PHP 5.3.

### Minimal installation

While installing the entire package manually or with composer is simple, convenient and reliable, you may want to include only vital files in your project. At the very least you will need [class.phpmailer.php](class.phpmailer.php). If you're using SMTP, you'll need [class.smtp.php](class.smtp.php), and if you're using POP-before SMTP, you'll need [class.pop3.php](class.pop3.php). For all of these, we recommend you use [the autoloader](PHPMailerAutoload.php) too as otherwise you will either have to `require` all classes manually or use some other autoloader. You can skip the [language](language/) folder if you're not showing errors to users and can make do with English-only errors. You may need the additional classes in the [extras](extras/) folder if you are using those features, including NTLM authentication, advanced HTML-to-text conversion and ics generation.
While installing the entire package manually or with composer is simple, convenient and reliable, you may want to include only vital files in your project. At the very least you will need [class.phpmailer.php](class.phpmailer.php). If you're using SMTP, you'll need [class.smtp.php](class.smtp.php), and if you're using POP-before SMTP, you'll need [class.pop3.php](class.pop3.php). For all of these, we recommend you use [the autoloader](PHPMailerAutoload.php) too as otherwise you will either have to `require` all classes manually or use some other autoloader. You can skip the [language](language/) folder if you're not showing errors to users and can make do with English-only errors. You may need the additional classes in the [extras](extras/) folder if you are using those features, including NTLM authentication and ics generation.

## A Simple Example

Expand Down Expand Up @@ -71,7 +78,6 @@ $mail->addReplyTo('info@example.com', 'Information');
$mail->addCC('cc@example.com');
$mail->addBCC('bcc@example.com');

$mail->WordWrap = 50; // Set word wrap to 50 characters
$mail->addAttachment('/var/tmp/file.tar.gz'); // Add attachments
$mail->addAttachment('/tmp/image.jpg', 'new.jpg'); // Optional name
$mail->isHTML(true); // Set email format to HTML
Expand All @@ -93,7 +99,7 @@ You'll find plenty more to play with in the [examples](examples/) folder.
That's it. You should now be ready to use PHPMailer!

## Localization
PHPMailer defaults to English, but in the [language](language/) folder you'll find numerous (39 at the time of writing) translations for PHPMailer error messages that you may encounter. Their filenames contain [ISO 639-1](http://en.wikipedia.org/wiki/ISO_639-1) language code for the translations, for example `fr` for French. To specify a language, you need to tell PHPMailer which one to use, like this:
PHPMailer defaults to English, but in the [language](language/) folder you'll find numerous (46 at the time of writing!) translations for PHPMailer error messages that you may encounter. Their filenames contain [ISO 639-1](http://en.wikipedia.org/wiki/ISO_639-1) language code for the translations, for example `fr` for French. To specify a language, you need to tell PHPMailer which one to use, like this:

```php
// To load the French version
Expand All @@ -104,10 +110,16 @@ We welcome corrections and new languages - if you're looking for corrections to

## Documentation

Generated documentation is [available online](http://phpmailer.github.io/PHPMailer/).
Examples of how to use PHPMailer for common scenarios can be found in the [examples](examples/) folder. If you're looking for a good starting point, we recommend you start with [the gmail example](examples/gmail.phps).

There are tips and a troubleshooting guide in the [GitHub wiki](https://github.com/PHPMailer/PHPMailer/wiki). If you're having trouble, this should be the first place you look as it's the most frequently updated.

Complete generated API documentation is [available online](http://phpmailer.github.io/PHPMailer/).

You'll find some basic user-level docs in the [docs](docs/) folder, and you can generate complete API-level documentation using the [generatedocs.sh](docs/generatedocs.sh) shell script in the docs folder, though you'll need to install [PHPDocumentor](http://www.phpdoc.org) first. You may find [the unit tests](test/phpmailerTest.php) a good source of how to do various operations such as encryption.

If the documentation doesn't cover what you need, search the [many questions on StackOverflow](http://stackoverflow.com/questions/tagged/phpmailer), and before you ask a question about "SMTP Error: Could not connect to SMTP host.", [read the troubleshooting guide](https://github.com/PHPMailer/PHPMailer/wiki/Troubleshooting).

## Tests

There is a PHPUnit test script in the [test](test/) folder.
Expand All @@ -128,6 +140,14 @@ With the move to the PHPMailer GitHub organisation, you'll need to update any re

Please *don't* use the SourceForge or Google Code projects any more.

## Sponsorship

Development time and resources for PHPMailer are provided by [Smartmessages.net](https://info.smartmessages.net/), a powerful email marketing system.

<a href="https://info.smartmessages.net/"><img src="https://www.smartmessages.net/img/smartmessages-logo.svg" width="250" height="28" alt="Smartmessages email marketing"></a>

Other contributions are gladly received, whether in beer 🍺, T-shirts 👕, Amazon wishlist raids, or cold, hard cash 💰.

## Changelog

See [changelog](changelog.md).
Expand Down
1 change: 1 addition & 0 deletions MultiMailer/PHPMailer-5.2.10/VERSION
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
5.2.10
Original file line number Diff line number Diff line change
@@ -1,5 +1,40 @@
# ChangeLog

## Version 5.2.10 (May 4th 2015)
* Add custom header getter
* Use `application/javascript` for .js attachments
* Improve RFC2821 compliance for timelimits, especially for end-of-data
* Add Azerbaijani translations (Thanks to @mirjalal)
* Minor code cleanup for robustness
* Add Indonesian translations (Thanks to @ceceprawiro)
* Avoid `error_log` Debugoutput naming clash
* Add ability to parse server capabilities in response to EHLO (useful for SendGrid etc)
* Amended default values for WordWrap to match RFC
* Remove html2text converter class (has incompatible license)
* Provide new mechanism for injecting html to text converters
* Improve pointers to docs and support in README
* Add example file upload script
* Refactor and major cleanup of EasyPeasyICS, now a lot more usable
* Make set() method simpler and more reliable
* Add Malay translation (Thanks to @nawawi)
* Add Bulgarian translation (Thanks to @mialy)
* Add Armenian translation (Thanks to Hrayr Grigoryan)
* Add Slovenian translation (Thanks to Klemen Tušar)
* More efficient word wrapping
* Add support for S/MIME signing with additional CA certificate (thanks to @IgitBuh)
* Fix incorrect MIME structure when using S/MIME signing and isMail() (#372)
* Improved checks and error messages for missing extensions
* Store and report SMTP errors more consistently
* Add MIME multipart preamble for better Outlook compatibility
* Enable TLS encryption automatically if the server offers it
* Provide detailed errors when individual recipients fail
* Report more errors when connecting
* Add extras classes to composer classmap
* Expose stream_context_create options via new SMTPOptions property
* Automatic encoding switch to quoted-printable if message lines are too long
* Add Korean translation (Thanks to @ChalkPE)
* Provide a pointer to troubleshooting docs on SMTP connection failure

## Version 5.2.9 (Sept 25th 2014)
* **Important: The autoloader is no longer autoloaded by the PHPMailer class**
* Update html2text from https://github.com/mtibben/html2text
Expand Down Expand Up @@ -64,7 +99,7 @@
* Better default behaviour for validateAddress

## Version 5.2.7 (September 12th 2013)
* Add Ukranian translation from @Krezalis
* Add Ukrainian translation from @Krezalis
* Support for do_verp
* Fix bug in CRAM-MD5 AUTH
* Propagate Debugoutput option to SMTP class (@Reblutus)
Expand Down Expand Up @@ -502,7 +537,7 @@ NOTE: will NOT work with PHP5 in E_STRICT error mode
## Version 1.15 (Fri, Jun 15 2001)
Note: these changes contributed by Patrice Fournier
* Changed all remaining \n to \r\n
* Bcc: header no longer writen to message except
* Bcc: header no longer written to message except
when sent directly to sendmail
* Added a small message to non-MIME compliant mail reader
* Added Sender variable to change the Sender email
Expand Down
Loading

0 comments on commit 10f3a6b

Please sign in to comment.