The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Automatically send emails when clicking on button
indra1997
post Aug 30 2023, 05:18 AM
Post #1





Group: Members
Posts: 1
Joined: 30-August 23
Member No.: 29,038



I created an HTML email template, and I want to use it for my clients. In the email template there is a standard button. Now I was wondering if I can make it so that when someone presses that button that an email is automatically sent with the request.

For example:
There is a button in the mail where they can press that they want to buy a certain product. I would like that when they press it that an email automatically comes to my sales colleagues, who can then contact the person again. Only I only get it arranged that a draft mail opens with my email address and the information they pressed. Only then they still have to send it themselves.

My html code is this:
<!DOCTYPE html>
<html>
<body>
<h2>Product aanvraag Contact Form</h2>
<form action="mailto:emailid@example.com" method="post" enctype="text/plain">
Name:<br><input type="text" name="sname"> <br>
Product:<br><input type="text" name="sproduct"><br>
<input type="submit" value="Send">
</form>
</body>
</html>
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
CharlesEF
post Aug 30 2023, 11:02 AM
Post #2


Programming Fanatic
********

Group: Members
Posts: 1,981
Joined: 27-April 13
From: Edinburg, Texas
Member No.: 19,088



The 'mailto:' only works if the user has an e-mail program installed on their local computer. It does not work with e-mail web clients.

To do what you want you need to use server side code, like PHP.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 27th April 2024 - 11:56 PM