Jump to content

Recommended Posts

have 3 days try this.. i am about to pop-up :
 i want to make a form has 2 submit buttons one submit to page itself (easy) and another button same form but submit tro another pge.. like this

 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>

<body>

<form method="post" enctype="multipart/form-data" action="<?php echo $_SERVER['PHP_SELF']; ?>">
   <input type="text" name="name"><br>
   <input type="submit" name="submit" value="Submit Form"><br>
   <input type="image" name="camper" onclick="submitForm('repo_.php')" value="camper" src="images/botonasis_g.png" onMouseOver="this.src='images/botonasis_c.png'" onMouseOut="this.src='images/butonasis_g.png'"  class="submit_button" />
</form>
<?php
if(isset($_POST['submit']))
{
    $name = $_POST['name'];
    echo "User Has submitted the form and entered this name : <b> $name </b>";
    echo "<br>You can use the following form again to enter a new name.";
}
?>
</body>
</html>

 

this cause i want make appointmnet for a doctor.. user select date and then i will make a dropdown with avalilable time (thats the submit to SELF   and the submit to another page wuth date and time to make the appointmnent..

 

 

VERY VERY tnx!!!

Link to comment
https://forums.phpfreaks.com/topic/298276-hyelp-with-php-foprms/
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.