Skip to content
Advertisement

I cannot seem to get my contact form working in HTML/PHP (new to PHP and completely stuck)

I am building a website and cannot get the contact form working on it’s designated page, when I click it I am supposed to see a url that says

JavaScript

However I am not getting this error, I am instead just getting sent to the file with the php code in it, this happens to be:

JavaScript

Anyway, here is the HTML code on the website that I am using

JavaScript

Here is my Php code that is on the contactform.php file.

JavaScript

Sorry if I have missed anything, I can repost with more details if so, just getting near my deadline and this roadblock has me stumped.

Advertisement

Answer

<input type="submit" value="Send" name="send"></input>

Explanation:

Since you’re checking in your php file, isset($_POST['send']) , you are not passing the name send to the request, that’s why the statement goes falsy

User contributions licensed under: CC BY-SA
3 People found this is helpful
Advertisement