Recipe 19 | Building a Simple Contact Form |
Problem
Websites—even mostly static websites—should provide a way for visitors to contact the site’s owner. An email address isn’t always good enough; it’s not inviting or engaging for the user, and it makes it harder for the site owner to sort and organize messages that come from visitors. Sites should have an easy, intuitive way for visitors to get in touch.
Our current website has no way to contact us, and we’re concerned that we’ve missed out on potential business opportunities as a result. Our manager wants us to create a simple form that sends us an email.
Ingredients
-
A server running PHP
Solution
A contact form lets visitors email us without having an email client configured, making it more likely ...
Get Web Development Recipes, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.