I am using HTML for the contact form fields and I wish to redirected the inputs to another webpage and have it displayed there. Is there a way to do it with PHP? Thank you!

I am using HTML for the contact form fields and I wish to redirected the inputs to another webpage and have it displayed there. Is there a way to do it with PHP? Thank you!

Yes.. You have to use form tag in your html form and specify the action property like

<form method="post" action="secondPage.php">
/* Your html form design here */
</form>

You can display the posted values in secondPage.php

ya you can do this use the following code to do this:-

form.html
<form action="display.php" method="POST">
Name<input type="text" name="u_name" placeholder="enter your name">
//other fields u want to add,add your code here......
</form>

display.php

<?php
echo $_POST['u_name'];
?>

If your problem is solved mark it as solved...

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.