HTML联系表格格式电子邮件奇怪

问题描述:

我正在制作一个用户可以键入的联系表格,然后当他们点击提交时,它会打开Outlook的输入。问题是输出非常混乱。它输出这样的:HTML联系表格格式电子邮件奇怪

name=John+Smith&email=I+am+contacting+you&comment=example+text+here 

我想输出更喜欢:

name=John Smith email=I am contacting you comment=example text here 

这有可能与此HTML5代码:

<form method="post" name="contact" action="mailto:[email protected]">   
       <p>   
       <label>Name</label> 
       <input name="name" value="Your Name" input type="text" size="50" /> 
       <label>Email</label> 
       <input name="email" value="Your Email" input type="text" size="50" /> 
       <label>Your Comments</label> 
       <textarea rows="5" cols="5" name="comment"></textarea> 
       <br /> 
       <input class="button" input type="submit" />   
       </p>   
      </form> 

因为我们还没有指定,否则,您的表单使用默认的enctype application/x-www-form-urlencoded“发送”。

将属性enctype="text/plain"添加到您的表单元素。

+0

谢谢,那正是我期待的。 – DumbQuesionGuy314 2013-03-21 15:14:15