Skip to content

Contact form made using Django, Redis and Celery which notifies receiver and sender through email when sender submits the form.

License

Notifications You must be signed in to change notification settings

iamakkkhil/ContactForm-Django

Repository files navigation

Contact Form using Django + Celery

This is a contact form project, you can use in personal portfolio websites or anywhere where people will like to contact you.

When you submit the form it will save the details of the person who tried contacting you inside the database and also sends an email message both to the ower of contact form and person who tried conatcting with a personalised message.

Tech stack:

                       


Setup :

  1. Install the requirements.txt in a virtual env.

    pip install -r requirements.txt
    

    Note: Redis installation for Ubuntu here

  2. Update your email address in settings.py file which will be used for sending an email.

  3. Update .env file by saving your email's password into it.

  4. Open four terminals with the virtual env created using requirements.txt file

    1. Terminal 1 : Start Django server.

      python manage.py runserver
      

      Note : Your directory should be same as manage.py file.

      Terminal1

    2. Terminal 2 : Starting Redis server ie. Message Broker.

      redis-server
      

      Make sure you have install redis properly.

      Terminal2

    3. Termial 3 : Starting Redis CLI to interact with our Django Application.

      redis-cli
      

      Terminal3

    4. Termial 4 : Running the Celery worker server i.e. connecting Celery to Redis by using below command.

      celery -A PortfolioContact worker --loglevel=INFO
      

      Terminal4

  5. Follow the link from Terminal 1 to your local host http://127.0.0.1:8000/ .

  6. Submit the form to see the results.

Working Screenshots:

  1. Contact Form:

    ContactForm_1

  2. After submitting form:

    ContactForm_2

  3. Email to owner:

    Email_1

  4. Email to client who submitted the form:

    Email_2

About

Contact form made using Django, Redis and Celery which notifies receiver and sender through email when sender submits the form.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published