Form Handling .php not working in wordpress


I insert a form in my blog post

This code is inserted in the post

<form action="welcome.php" method="post">
Name: <input type="text" name="name"><br>
E-mail: <input type="text" name="email"><br>
<input type="submit">

name andemail text fields and a submit button.After that is create a welcome.php file.

welcome.php file code is as following.

<?php get_header(); ?>
Welcome <?php echo $_POST["name"]; ?><br>
Your email address is: <?php echo $_POST["email"]; ?>
<?php get_sidebar('single'); ?>
<?php get_footer(); ?>

but when i fille name and email in text filed and click on submit button. not found error and form is not processed




Try using the code below:

<form action="<?php echo get_stylesheet_directory_uri(); ?>/welcome.php" method="post">

People are also looking for solutions to the problem: php - IntlDateFormatter::parse doesn't work?


Didn't find the answer?

Our community is visited by hundreds of web development professionals every day. Ask your question and get a quick answer for free.

Ask a Question

Write quick answer

Do you know the answer to this question? Write a quick response to it. With your help, we will make our community stronger.

Similar questions

Find the answer in similar questions on our website.