form submit - How do I display text above after submitting it into a textbox HTML -


i'm trying create area in can enter text text box , display written text onto box above in html. i'm new html appreciated. drew beautiful picture of i'm trying make. enter image description here

the best way deal situation use javascript or jquery javascript's library itself. let me show how should in jquery

<script   src="https://code.jquery.com/jquery-3.2.1.min.js"   integrity="sha256-hwg4gsxgfzhoseeamdoygbf13fyquitwlaqgxvsngt4="   crossorigin="anonymous"></script>  <script>  	$(document).ready(function(){      	$("#form-to-be-submitted").click(function(){          	$(".whatever-styling-you-want").html($("#textbox").val());          });      });  	  </script>    <div class="whatever-styling-you-want">    </div>  <!-- text box , submit button -->  <div>        <input type="text" id="textbox" placeholder="please input text here..."/>        <input id="form-to-be-submitted" value="submit" type="button"/>  </div>

javascript's way same. no need use click function use javascript's on function 'click' event. hope helps.


Comments

Popular posts from this blog

php - Vagrant up error - Uncaught Reflection Exception: Class DOMDocument does not exist -

vue.js - Create hooks for automated testing -

Add new key value to json node in java -