Best way of capturing user email address on website
<p>I currently have a form that on a coming soon page on my web server that I need to capture entered email addresses and send it to my email address e.g. <em>example@hotmail.com</em>. </p>

<p>What would be the best way of accomplishing this using PHP?</p>

<pre><code>&lt;form method="post"&gt;

&lt;input class="emailsubscribe mobile clearfix" type="text" name="mail" 
placeholder="Enter your email" onFocus="if(!this._haschanged)
{this.value=''};this._haschanged=true;"/&gt;

&lt;input class="emailsubscribe desktop clearfix" type="text" name="mail" 
placeholder="Enter your email to stay up to date" onFocus="if(!this._haschanged)
{this.value=''};this._haschanged=true;"/&gt;

&lt;input class="emailsubmit clearfix" type="submit" name="submit"/&gt;

&lt;/form&gt;
</code></pre>

<p>Thanks in advance!</p>
