-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b9162c3
commit 49e259f
Showing
4 changed files
with
101 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
<?php | ||
|
||
include '../vendor/autoload.php'; | ||
|
||
use Phant\EmailSender\Service\EmailBuilder; | ||
|
||
$emailBuilder = new EmailBuilder(); | ||
|
||
$bodyHtml = nl2br( | ||
'Hello, | ||
Would you like to find out more about our work? | ||
Visit our Github page:' | ||
); | ||
$bodyHtml .= $emailBuilder->buildCta( | ||
'https://github.com/PhantPHP', | ||
'Github' | ||
); | ||
$bodyHtml .= nl2br( | ||
'Thank you for your trust, | ||
The Phant team' | ||
); | ||
|
||
$html = $emailBuilder->build( | ||
$bodyHtml, | ||
'image/logo.png', | ||
'image/logo.png', | ||
nl2br( | ||
'Made with passion, in France | ||
© Phant ' . date('Y') | ||
) | ||
); | ||
|
||
echo $html; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
|
||
include '../vendor/autoload.php'; | ||
|
||
use Phant\EmailSender\Service\EmailBuilder; | ||
|
||
$emailBuilder = new EmailBuilder(); | ||
|
||
$bodyHtml = nl2br( | ||
'<b>Lorem ipsum dolor sit amet</b> | ||
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. | ||
Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. | ||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. | ||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.' | ||
); | ||
|
||
$html = $emailBuilder->build( | ||
$bodyHtml, | ||
'image/logo.png', | ||
'image/logo.png', | ||
nl2br( | ||
'Made with passion, in France | ||
© Phant ' . date('Y') | ||
) | ||
); | ||
|
||
echo $html; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
<?php | ||
|
||
include '../vendor/autoload.php'; | ||
|
||
use Phant\EmailSender\Service\EmailBuilder; | ||
|
||
$emailBuilder = new EmailBuilder(); | ||
|
||
$bodyHtml = nl2br( | ||
'Hello, | ||
Here is the verification code you requested :' | ||
); | ||
$bodyHtml .= $emailBuilder->buildOtp('123456'); | ||
$bodyHtml .= nl2br( | ||
'This single-use code will expire in 15 minutes. | ||
Thank you for your trust, | ||
The Phant team' | ||
); | ||
$bodyHtml .= $emailBuilder->buildMeta([ | ||
'IP address' => $_SERVER['REMOTE_ADDR'], | ||
'Browser' => $_SERVER['HTTP_USER_AGENT'], | ||
'Request date' => date('Y/m/d H:i:s'), | ||
]); | ||
|
||
$html = $emailBuilder->build( | ||
$bodyHtml, | ||
'image/logo.png', | ||
'image/logo.png', | ||
nl2br( | ||
'Made with passion, in France | ||
© Phant ' . date('Y') | ||
) | ||
); | ||
|
||
echo $html; |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.