title: html5 basic alert and textbox
body: <p>I am a newbie in HTML5 and javascript. 
  I want an alert box to display data(firstname and lastname). 
  Data must be taken from textboxes on the form.
  My code is below, but the alertbox doesn't work.</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;body&gt;
  
  &lt;form action="demo_form.asp" method="get"&gt;
  First name: &lt;input type="text" name="fname" /&gt;&lt;br&gt;
  Last name: &lt;input type="text" name="lname" /&gt;&lt;br&gt;
  
  &lt;/form&gt;
  &lt;script&gt;
  function display_alert()
    {
     alert(fname +lname);
    }
  &lt;/script&gt;
  
  &lt;input type="button" onclick="display_alert()" value="Display alert box"&gt;
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>