I am new to PHP, and have a simple calculator implemented to perform basic calculations.
The result(or when a button clicked, the respective number) is displayed in the input
<input type="text" id="textbox" value="<?php echo $result ?>" name="result"/>
.
I have created a clear button using <input value="Clear" type='submit' onclick='document.getElementById("textbox").value="";' />
I want to implement a button similar to 'backspace' key in keyboard, which when clicked once, would clear one character in the input field. Is it possible in PHP? Please help me out with the code. tq for suggestions:)