binomedev / contact
Contact
Fund package maintenance!
binomedev
Requires
- php: ^7.4|^8.0
- artesaos/seotools: ^0.20.0
- illuminate/contracts: ^8.0
- laravel/nova: ^3.0
- optimistdigital/nova-settings: ^3.1
- spatie/laravel-package-tools: ^1.1
- whitecube/nova-flexible-content: ^0.2.4
Requires (Dev)
- orchestra/testbench: ^6.0
- phpunit/phpunit: ^9.3
- spatie/laravel-ray: ^1.9
- vimeo/psalm: ^4.4
This package is auto-updated.
Last update: 2021-07-20 23:01:22 UTC
README
A package to manage contact information such as: email, phone, socials and forms.
Installation
You can install the package via composer:
composer require binomedev/contact
Install nova-settings
composer require optimistdigital/nova-settings
Add the following line to the boot method within the NovaServiceProvider.php in order to be able to modify contact data withing Nova.
use Binomedev\Contact\ContactSettings; // NovaServiceProvider.php public function boot() { // ... ContactSettings::boot(); }
You can publish and run the migrations with:
php artisan vendor:publish --provider="Binomedev\Contact\ContactServiceProvider" --tag="contact-migrations" php artisan migrate
You can publish the config file with:
php artisan vendor:publish --provider="Binomedev\Contact\ContactServiceProvider" --tag="contact-config"
This is the contents of the published config file:
return [ 'default_email_receiver' => env('MAIL_FROM_ADDRESS'), 'save_messages' => true, 'emails' => [ // contact@domain.com ], 'numbers' => [ // +32 1111 111 111 ], 'socials' => [ ], 'addresses' => [ [ 'name' => 'Office', 'street' => '', 'number' => '', 'postcode' => '', 'city' => '', 'country' => '', ], ], 'schedule' => [ [ 'days' => '', 'hours' => '', ] ], ];
Usage
use Binomedev\Contact\ContactFacade; // Subscribe a new email $subscriber = ContactFacade::subscribe( $data['email'], $data['name'], $data['phone'], );
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
License
The MIT License (MIT). Please see License File for more information.