Download the PHP package disjfa/mail-bundle without Composer

On this page you can find all versions of the php package disjfa/mail-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package mail-bundle

Mail bundle

Check on packagist MIT License

Watch on GitHub Star on GitHub Tweet

Why is this bundle here

In every project i need to build a way to send emails. Now symfony has released the Mime Component and the Mailer Component. Lets see what we can do to make live easier for us people who send emails.

Instalation

Setup the interface

Setup the routes in config/routes/disjfa_mail.yaml. Here you can edit emails setup in your application.

Make you own template

Create a class that extends the MailInterface. Implement the name, subject and content as you want. You can inject the Translator to add simple translations or the twig Environment to render out templates.

In your templates there should be no twig variables. Escape those, like this: {{ '{{' }} email {{ '}}' }}. All the variables used are parsed and collected. The original variables are the only ones that should be used.

If you made a class it will be autoload in the MailCollection collection. And so editable if you have set up some routes for the interface.

Sending emails

Next up is sending emails. In your code just make a message or function that sets up the email.

And done! Mail sent. Now it is time to setup emails and make more in your application.

Extend the templates

You can manage the templates as is. But you probably want to integrate the files in your own system. Just create a file in your application in templates/bundles/DisjfaMailBundle/layout.html.twig and add a body block.

And you are good to go. Or you can just extend your own template. Just make sure you use a block named body. You can also just extend the rest of the files as you wish. Just name them like we set up the files.

One thing missing

One thing missing is sending the emails. We do not have to set up the mailing bit of the application. You can do that yourself. Check the transports on how to set up your own mailer as you wish.

And that is about it.

Now you can make your own emails. Set them up. Create a method to send emails. And when you have set up your favorite mailer you can send them!

Help

This bundle is a nice way to extend your workflow. But it can be improved. If you have any ideas or solutions to do so don't be shy and tell us! We can only make stuff better in the end.

Enjoy!

Use the bundle. Check what the bundle does. Fork. Make your own. This is here just to make live easier for us all. Make something beautiful.


All versions of mail-bundle with dependencies

PHP Build Version
Package Version
Requires php Version ^7.2.9
ramsey/uuid Version ^3
symfony/form Version ^4|^5
symfony/mailer Version ^4|^5
symfony/mime Version ^4|^5
symfony/orm-pack Version ^1.0
symfony/translation Version ^4|^5
symfony/twig-bundle Version ^4|^5
symfony/validator Version ^4|^5
twig/cssinliner-extra Version ^2.12
twig/extra-bundle Version ^2.12
twig/inky-extra Version ^2.12
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package disjfa/mail-bundle contains the following files

Loading the files please wait ....