LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Closed Thread
  Search this Thread
Old 10-21-2009, 01:27 PM   #1
esteeven
Senior Member
 
Registered: Oct 2001
Location: Bristol UK
Distribution: Arch Slackware Ubuntu
Posts: 1,082

Rep: Reputation: 52
validated form >> redirect to php form


I have an html form which contains this action :

<form action="<?=$_SERVER['PHP_SELF']?>" method="post">

The validation I have set up works (finally!!) using -

// import the validation library
require("validation.php");

Now that the form works, I would like to email the contents. Originally, before I started to validate the form, the form was processed by regform.php.

<form action="regform.php" method="post">

I see from some examples I have found that the following is possible -

// no errors! redirect the user to the thankyou page (or whatever)
else
{
$message = "All fields have been validated successfully!";

// here you would either email the form contents to someone or store it in a database.
// To redirect to a "thankyou" page, you'd just do this:
// header("Location: thanks.php");
}

I have tried to use my regform.php to process the data post validation but I can't make it work. Am I on the right road?

Thanks
 
Old 10-21-2009, 04:59 PM   #2
crabboy
Senior Member
 
Registered: Feb 2001
Location: Atlanta, GA
Distribution: Slackware
Posts: 1,821

Rep: Reputation: 121Reputation: 121
Closing duplicate post.
 
  


Closed Thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
validated form >> redirect to php form esteeven Programming 1 10-21-2009 01:18 PM
How to redirect after form self-post cmnorton Programming 7 04-03-2009 03:02 PM
how to show results of a php query from a form on the main form texmansru47 Programming 2 06-27-2008 01:26 PM
PHP: build query from form entry, then display results in the same form tonedeaf1969 Programming 4 06-22-2007 07:55 AM
How can i redirect where a form posts to? verbatim Programming 2 05-28-2005 12:24 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 08:50 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration