Add image upload to html contact form?

3 replies
  • WEB DESIGN
  • |
Hey guys. I know how to create an HTML contact form. My question is......can I add an image upload function to the contact form? For instance: Have the fields: "Name" - "E-mail Address" and then under that a "browse" button for the user to select their image and then when they submit the form, it will show up in my inbox with their name, email address and the image they selected.

Thanks.
#add #contact #form #html #image #upload
  • Profile picture of the author Steven Garret
    you wont be able to have the file go to your inbox as an attachment or anything but you can code this using php into your own forms or use a paid service to "store" the files for you on their servers..
    If you do a little research you should be able to use the following links as guides to what is available..

    php code on your won server:
    (not a aff link) tizag (dot) com/phpT/fileupload (dot) php

    example of a service to host it for you:
    (not a aff link) uploadthingy (dot) com

    hope that helps..

    STEVE
    {{ DiscussionBoard.errors[3082425].message }}
    • Profile picture of the author Big Squid
      You can add an image to your form using <input type="file"> tag...

      You probably could have that image sent to your email in an HTML email, but it's gonna be a bigger pain in the rear to develop.

      A better option (one that I use myself) is to have a link sent to my email that opens up a browser page to display the image.
      {{ DiscussionBoard.errors[3083537].message }}
  • Profile picture of the author wello
    just a question: what if they upload a major virus...?
    you might have to be careful designing that upload form...
    {{ DiscussionBoard.errors[3083851].message }}

Trending Topics