Make the index.html an index.php and move your php code to the top of the index file, then make the form submit to itself. This allows you to do live user feedback using echo or similar – without the need for AJAX 🙂
solved Set the returned value from php using AJAX [closed]