The answer is as given in the comment by brombeer:
if(isset($_POST['submit'])){will never be triggered, there is no
HTML element withname="submit"– brombeer
solved Seperating html form from php file
The answer is as given in the comment by brombeer:
if(isset($_POST['submit'])){will never be triggered, there is no
HTML element withname="submit"– brombeer
solved Seperating html form from php file