Download the PHP package riverskies/laravel-newsletter-subscription without Composer
On this page you can find all versions of the php package riverskies/laravel-newsletter-subscription. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download riverskies/laravel-newsletter-subscription
More information about riverskies/laravel-newsletter-subscription
Files in riverskies/laravel-newsletter-subscription
Package laravel-newsletter-subscription
Short Description Simple newsletter subscription for Laravel projects.
License MIT
Informations about the package laravel-newsletter-subscription
Laravel Newsletter Subscription
A simple package to enable newsletter subscriptions within the context of a Laravel application.
Installation
Laravel 5.4 or earlier
Add the service provider to your config/app.php
file:
Usage
Include a simple form anywhere within your pages.
You might also want to include notification display on the same page.
Subscriptions
This package collects email addresses and stores them in the database. You can access these subscriptions by querying the Riverskies\LaravelNewsletterSubscription\NewsletterSubscription
Eloquent model.
Note
This package uses the Mail
facade to deliver the emails and delivery is queued, so ensure your QUEUE_DRIVER
in your environment config is set accordingly.
Publishing assets
You can override the database table name, the associated URLs, email template format and the session key by overriding the default configuration values.
You can design the confirmation email by overriding the default view.
You can localise/change the messages by overriding the default localisation values.
Considerations
This package uses hashids/hashids
to help derive unsubscribe links from the id
fields of the subscription records. Those hashes are not stored in the database but instead encoded/decoded at runtime. To generate unique codes, this package uses the APP_KEY
from the environment settings. If that changes, previously generated unsubscribe links will no longer work.
Contributions
PRs are welcome as long as they are following PSR-2
standards and include all the corresponding tests that the change requires (not to mention that those should not break any previous behaviour either).