How to Create a Contact Form Using PHP

When you create a contact form in PHP, there’s a couple key parts you need to make sure are in place so the person actually using the form doesn’t want to suddenly get into knife-throwing (at your head) afterward.

You need validation that make sense and is easy to understand.

I prefer the kind that shows up all at the top of the form, because when you have a long form and missed one checkbox and have to go hunting through the form like you’re looking for a lost sock… knife-throwing becomes a viable option.

Next, you need to make sure when there is an error, you don’t lose all the data you entered already.

Nothing will get knives, bricks, cars, kitchen sinks, those big bats with spikes on them… thrown at your head faster than making me re-enter all the form field data again because I forgot to check whether I like chocolate bunnies or not.

With all that in mind, I humbly present to you MY contact form tutorial:

It’s possible this could be YOUR contact form… meaning you’re obviously cool like me and think the way it’s built is perfect.

Or, you may to prefer to hurl insults at me on YouTube about it.

Either way, there’s 100 ways to skin a cat (but why would you)… and this is just one. Use it if you like it.

P.S. Ah yes! That pesky source code. You can get that as a supporting listener of the podcast. Learn how to do that here: http://johnmorrisonline.com/patreon

P.P.S. If you liked the show, give it a like and share with the communities and people you think will benefit. And, you can always find all my tutorials, podcast episodes and more on johnmorrisonline.com, @jpmorris on Twitter and youtube.com/johnmorrisvideo.

Subscribe to the Podcast

[saf]

Do you want more freelance clients?

I’ll show you what I learned over the last 15 years to grind out (from absolute scratch) a backlog of new clients wanting to hire you. Who your best client prospect are, what services you should be offering them, where to find them and more. Just enter your email address in the box below and let’s get started:

Share on facebook
Facebook
Share on twitter
Twitter
Share on linkedin
LinkedIn
Share on reddit
Reddit
Share on pinterest
Pinterest
John Morris

JOHN MORRIS

I’m a 15-year veteran of freelance web development. I’ve worked with bestselling authors and average Joe’s next door. These days, I focus on helping other freelancers build their freelance business and their lifestyles.

You might also like

This Post Has One Comment

  1. Hey Erika! Cool you’re taking it over there. For SkillShare, the code is in the “Class Project” section. That’s the only place they let me upload any files. It’s all in that one zip file there. There’s another download for the PDFs for some of the database videos. Those are there, too.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Do you want more freelance clients?

Enter your email below to get started building your system for consistently bringing in new freelance clients:

WHAT OTHERS ARE SAYING

Thabo Motsoahae

John is one of the best instructors I have come across, I learned a lot from his online tutorials.

Sukh Plaha

John is a fantastic and patient tutor, who is not just able to share knowledge and communicate it very effectively – but able to support one in applying it. However, I believe that John has a very rare ability to go further than just imparting knowledge and showing one how to apply it. He is able to innately provoke one’s curiosity when explaining and demonstrating concepts, to the extent that one can explore and unravel their own learning journey. Thanks very much John!

Ray Edwards

I recommend John every chance I get. If every person I worked with were as committed to excellence, punctuality, value, and unquestionable integrity… the world would be a better place. Highest recommendation.

Daniel Mohlendick

On the Freelancing on Upwork course: “This is by far the best course i have watched on Skillshare!! Thank you so much.”

Lewis Howes

John is amazing at building membership sites. He converted one of my sites over from it’s existing (hardly working) platform over to the clean and simple to use WishList membership platform. I highly recommend using John and WishList for any of your membership site needs.

Bob Patterson

Not only is John a very talented programmer and developer, he is also an excellent communicator. He has a talent for taking complex subjects and communicating them in terms that anyone can understand. This is a rare combination. This ability has enabled me to take my skills and knowledge to the next level. Thank you John for for all that you do.

Close Menu