Code Monkey home page Code Monkey logo

contactform's Introduction

Simple Contact Form with PHPMailer

A simple contact form with PHPMailer, reCAPTCHA and Bootstrap.

Use this to provide a simple contact form on your own website, and send the messages with SMTP. Or use this as a basis or example to create your own contact form.

Getting Started

  1. Download the latest version of the contact form: https://github.com/InfinityFreeHosting/contactform/releases
  2. Extract the archive on your own computer.
  3. Copy the config.example.php to config.php and edit the required settings.
  4. Upload the extracted files to a subdirectory of your hosting account (e.g. htdocs/contact/).
  5. Navigate to http://your-domain.epizy.com/contact/ and try out the form!

How to get your SMTP credentials

To be able to send messages with this contact form, you'll need a working SMTP service. InfinityFree does not provide this with free hosting, but you can use third party SMTP services.

A simple, free option to use is Gmail. You can use Gmail to send your messages like so:

  1. Sign up for a free Gmail account.
  2. Enable Two Factor Authentication on the Google account: https://myaccount.google.com/signinoptions/two-step-verification
  3. Generate an App Specific Password for the account: https://myaccount.google.com/apppasswords
  4. In the configuration file, set the SMTP Hostname smtp.gmail.com, enter your full Gmail address in the SMTP Username field and enter the App Specific Password in the SMTP Password field.

How to get your reCAPTCHA credentials

To prevent spammers from being able to abuse your contact form, reCAPTCHA has been integrated by default. reCAPTCHA is a free service from Google which can prevent automated scripts from using your form.

This contact form has been integrated with reCAPTCHA v2 with the Checkbox challenge. To use this, you will need to setup your site in reCAPTCHA like so:

  1. Go to the reCAPTCHA admin console: https://www.google.com/recaptcha/admin/create
  2. Enter a label you can use to identify your website.
  3. Choose the reCAPTCHA type "reCAPTCHA v2" and the version "Checkbox 'I'm not a robot'".
  4. Under Domains, enter the domain name of your website.
  5. Accept the reCAPTCHA terms and click Send.

contactform's People

Contributors

grendel7 avatar dependabot[bot] avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.