title: Textbox line number with enter key press
body: <p>I am trying to implement a <strong>text insertion field which should automatically number each row</strong> (based on the row break). </p>
  
  <p>The user should not be able to choose this by themselves or remove the numbers, the text field should from the beginning be configured as a numbered list.</p>
  
  <p>This is done in JQuery and I have not been able to find a solution.</p>
  
  <p>Below is what I have tried but it does not work as it needs to.
  I got solution from <a href="http://files.aw20.net/jquery-linedtextarea/jquery-linedtextarea.html" rel="nofollow noreferrer">LineAreaText Demo</a>.</p>
  
  <p>also <a href="http://jsfiddle.net/JamesHill/jMZKz/" rel="nofollow noreferrer">JSFIDDLE</a></p>
  
  <p>But need the structure as jsfiddle textbox like:</p>
  
  <hr>
  
  <pre><code>1. here is first line.
  2. when press enter key this two will add in this line and 
     now I am not pressing enter key so there is no next line 
     count.
  3. Now pressed enter and third is there as line number.
  </code></pre>
  
  <hr>
  
  <p>I have tried as</p>
  
  <ul>
  <li>Use editable div structure as above described but failed to put blank 
   when no enter key pressed and sentence is yet not completed.</li>
  <li>Use ajax htmleditor extender, But there is need to press orderred list icon button on top.</li>
  </ul>
  
  <p>Here is what JsFiddle using same as i needed to do.</p>
  
  <p><img src="https://i.stack.imgur.com/YiGcm.jpg" alt="enter image description here"></p>
  
  <p>I would very much appreciate any help or guidance in this since I am stuck now.</p>
  
  <p>Thanks in advance. </p>