levacic/mailto

A generator for "mailto:" links

1.0.2 2018-02-19 00:24 UTC

This package is auto-updated.

Last update: 2024-04-07 21:17:02 UTC


README

This class allows easy creation of mailto: links, and supports recipients within to:, cc:, and bcc: fields, and setting the subject and body of an email.

Example

<?php

$mailto = Levacic\Mailto\Generator::create()
	->to('person@example.com')
	->subject('Subject')
	->body('Hi there!');

?>

<a href="<?php echo $mailto; ?>">Send email!</a>

License

The code is licensed under the MIT license, which is available in the LICENSE file.