[Solved] xampp php not working


Possible problems

  1. Either, your contact.php would be in different directory.

  2. You are trying to access with WRONG URL, i mean path.

  3. You would have changed your port number to other. Check your Port Number, when you are accessing your main page (i.e. index.php or whatever).

Suggestion

If your index.php and contact.php are in same directory i.e. myproject. Then, it’s better to specify only contact.php rather than whole URL.

Don’t

<form method="POST" action="http://localhost/contact.php">

Do

<form method="POST" action="contact.php">

Note : Always use relative URL instead of actual URL.

UPDATE

When you clicked on SUBMIT button, then check your current URL path, whether it is changed to contact.php or not ?? I mean, it must localhost/contact.html to localhost/contact.php And I believe, It must. Since, form is a part of html, which means it doesn’t matter whether your server is running or not. But, yes, if your contact.php would be in different directory. Then your problem still persist.

13

solved xampp php not working