Installation: Contact Form


I am not updating these docs because my focus is on my new PHP Serverless Project.

My LaSalle Software's purpose was always a mixture of learning, marketing, and a basis for my own projects. It has, and is, fulfilling these purposes magnificently!

As always, contact me with your questions.

Admin Back-end App

You can see the contact form submissions in the back-end Nova admin with the contact form's back-end package. Make sure you have this in your composer.json's require:

"lasallesoftware/lsv2-contactformbackend-pkg": "^2.1",

There is a migration in the admin contact form package. This database table should already exist as it was created in your base admin app installation.

That's it for the back-end. The real fun is in the front-end.

Front-end App

Your composer.json should already have the package in the require:

"lasallesoftware/lsv2-contactformfrontend-pkg": "^2.1",

Please peruse the config and set the params as you see fit.

Please note that you can write your own contact form blade files. I very much recommend that you create a package for this! You can specify your own package with the "what_package_are_the_view_files" config parameter.

To place the contact form on its own "Contact Us" page, just add a link to:

  • This is the route
  • This is the controller
  • This is the blade file

  • The form itself is a "partial", so you can place it anywhere you want. Here is an example of placing it on the home page (scroll down).

    Here's what the contact will look like:

    Do note that the <h1> tag inherits text colour.

    Laravel takes care of the actual method you choose to send your emails. Please consult the Laravel Mail doc.

    I am using Amazon Web Service's Simple Email Service. Which means that I have to add the following to my composer.json:

    "aws/aws-sdk-php": "~3.0",

    For AWS SES set-up, this is what I did:
  • log into AWS console
  • "Simple Email Service"
  • "Go to Identity Management"
  • "Verify a New Domain" & checked "generate the DKIM"
  • logged into my domain zone record management provider
  • entered the SES zone records
  • From here, I waited for the verification. Just to be on the safe side, I also verified the email addresses I use for my contact forms.

    Then I went into IAM, and created a new group just for SES. Then I created a user just for using SES. Then generated the access and secret keys. These keys are not the same keys as I use for S3. Then entered these keys into the config/services.php directly (not via the .env). When your contact form works, you should request AWS to lift the quote of 200 emails per day (unless you are fine with a maximum of 200 emails per day).

    It's probably best to set up SES well before you actually need to use it, as it could take a few days for the verifications to complete.