A package to manage contact information such as: email, phone, socials and forms.
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' => '',
]
],
];
use Binomedev\Contact\ContactFacade;
// Subscribe a new email
$subscriber = ContactFacade::subscribe(
$data['email'],
$data['name'],
$data['phone'],
);
composer test
Please see CHANGELOG for more information on what has changed recently.
Please see CONTRIBUTING for details.
Please review our security policy on how to report security vulnerabilities.
The MIT License (MIT). Please see License File for more information.