如何在不使用outlook的情况下在html或客户端发送邮件? [英] How to send mail in html or client side without using outlook?

查看:118
本文介绍了如何在不使用outlook的情况下在html或客户端发送邮件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的代码



my code

<form id="contact-form" method="post" action="" >
                               <!--action="mailto:Info@Mali.arun44@gmail.com"-->
                               <div class="contact-form-loader"></div>
                               <fieldset>
                                   <div class="row">
                                       <div class="grid_2">
                                           <label class="name">
                                               <input id="nm" type="text" name="name" placeholder="Name:" value=""
                                                      data-constraints="@Required @JustLetters"/>
                                               <span class="empty-message">*This field is required.</span>
                                               <span class="error-message">*This is not a valid name.</span>
                                           </label>
                                       </div>
                                       <div class="grid_2">
                                           <label class="email">
                                               <input id="mail" type="text" name="email" placeholder="E-mail:" value=""
                                                      data-constraints="@Required @Email"/>
                                               <span class="empty-message">*This field is required.</span>
                                               <span class="error-message">*This is not a valid email.</span>
                                           </label>
                                       </div>
                                       <div class="grid_2">
                                           <label class="phone">
                                               <input id="mno" type="text" name="phone" placeholder="Phone:" value=""
                                                      data-constraints="@JustNumbers"/>
                                               <span class="empty-message">*This field is required.</span>
                                               <span class="error-message">*This is not a valid phone.</span>
                                           </label>
                                       </div>
                                   </div>
                                   <label class="message">
                                       <textarea name="message" placeholder="Message:" id="msg"
                                                 data-constraints='@Required @Length(min=20,max=999999)'></textarea>
                                       <span class="empty-message">*This field is required.</span>
                                       <span class="error-message">*The message is too short.</span>
                                   </label>
                                   <div class="btn-wrap">
                                       <a class="btn_3" href="#" data-type="reset">clear</a>
                                       <a class="btn_3" href="#" data-type="submit">send</a>
                                      <!-- <input id="bt1" type="submit" />-->
                                        <input type="button" value="Send Email" />
                                  <!--     contact@shivmaniinfotech.com-->
                                   </div>
                               </fieldset>
                               <div class="modal fade response-message">
                                   <div class="modal-dialog">
                                       <div class="modal-content">
                                           <div class="modal-header">
                                               <button type="button" class="close" data-dismiss="modal"
                                                       aria-hidden="true">×</button>
                                               <h4 class="modal-title">Modal title</h4>
                                           </div>
                                           <div class="modal-body">
                                               You message has been sent!
                                           </div>
                                       </div>
                                   </div>
                               </div>
                           </form>

推荐答案

你不能像这样发送它。



如果您想使用客户的电子邮件ID(和电子邮件服务器),邮件必须在Outlook /默认电子邮件客户端中打开。

如果您希望使用自己的电子邮件服务器/凭据,则无法在客户端执行此操作。它需要在服务器上进行配置。



建议您了解有关通过代码发送电子邮件的更多信息。
You can't simply send it like this.

If you wish to use client's email id (and email server), mail must be opened in outlook/default email client.
If you wish to use your own email server/credentials, you can't do it client side. It requires configuration at server.

Suggesting you to learn more about sending emails via code.


如果没有服务器交互,您可以'但是,最简单的方法是PHP的mail(),它也适用于免费托管服务提供商。



邮件(到,主题,消息,标题,参数);



在这里查找更多内容

PHP邮件( )功能 [ ^ ]
Without server interaction you can't, however simplest possible way is PHP's mail() which also works in Free Hosting providers.

mail(to,subject,message,headers,parameters);

Find more here
PHP mail() Function[^]


这篇关于如何在不使用outlook的情况下在html或客户端发送邮件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆