1. Go to this page and download the library: Download omh/laracontact library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
return [
/*
* Set the form path.
*/
'form_path' => '/contact-us',
/*
* Set the url redirection after submitting the contact us form.
*/
'redirectTo' => '/',
/*
* Set the contact us page title.
*/
'page_title' => 'Contact us',
/*
* Array of emails that should receive the contact request
*/
'notifiables' => ['[email protected]'],
/*
* Set to false to disable sending emails feature
*/
'send_mails' => true,
/*
* To configure correctly please visit https://developers.google.com/recaptcha/docs/start
*/
'recaptcha' => [
/*
*
* The secret key
* get site key @ www.google.com/recaptcha/admin
*
*/
'recaptcha_secret' => env('RECAPTCHA_SECRET'),
/*
*
* The secret key
* get site key @ www.google.com/recaptcha/admin
*
*/
'recaptcha_sitekey' => env('RECAPTCHA_SITEKEY'),
]
];
/*
* Set the url redirection after submitting the contact us form.
*/
'redirectTo' => '/my-custom-redirection',
/*
* Set the url redirection after submitting the contact us form.
*/
'page_title' => 'My Custome title',
/*
* Array of emails that should receive the contact request
*/
'notifiables' => ['[email protected]'],
/*
* Set to false to disable sending emails feature
*/
'send_mails' => false,
/**
* The event listener mappings for the application.
*
* @var array
*/
protected $listen = [
Laracontact\Events\ContactRequestEvent::class => [
// your own listeners
],
];
sh
php artisan vendor:publish --tag="laracontact-migration"
php artisan vendor:publish --tag="laracontact-config"
sh
php artisan migrate
sh
php artisan vendor:publish --tag="laracontact-views"
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.