Oct 14th, 2011, 5:55 AM
All -
Sure could use some help ... with a multi-page form.
I am able to successfully complete the setup of a form using FT.
However, FT is only capturing form data from the first page of a three page form.
What am I doing wrong?
Here is my code for the three page form and "thank you" page.
Form Page #1:
Form Page #2:
Form Page #3:
Thank You Page:
Many thanks for the assistance.
Jeff -
Sure could use some help ... with a multi-page form.
I am able to successfully complete the setup of a form using FT.
However, FT is only capturing form data from the first page of a three page form.
What am I doing wrong?
Here is my code for the three page form and "thank you" page.
Form Page #1:
PHP Code:
<?php
require_once("x/global/api/api.php");
$fields = ft_api_init_form_page("", "test");
$params = array(
"submit_button" => "submit",
"next_page" => "form-2b.php",
"form_data" => $_POST
);
ft_api_process_form($params);
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>form</title>
</head>
<body>
<!-- Start of FORM -->
<form action="<?php echo $_SERVER["PHP_SELF"]?>" method="POST">
First Name: <input type="text" name="FirstName" value="">
<br />
<br />
Last Name: <input type="text" name="LastName" value="">
<br />
<br />
<input type="submit" name="submit" value="submit">
</form>
<!-- End of FORM -->
</body>
</html>
Form Page #2:
PHP Code:
<?php
require_once("x/global/api/api.php");
$fields = ft_api_init_form_page();
$params = array(
"submit_button" => "submit",
"next_page" => "form-3b.php",
"form_data" => $_POST,
"no_sessions_url" => "form-1b.php"
);
ft_api_process_form($params);
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>form</title>
</head>
<body>
<!-- Start of FORM -->
<form action="<?php echo $_SERVER["PHP_SELF"]?>" method="POST">
Address: <input type="text" name="Address" value="">
<br />
<br />
City: <input type="text" name="City" value="">
<br />
<br />
State: <input type="text" name="State" value="">
<br />
<br />
Zip: <input type="text" name="Zip" value="">
<br />
<br />
<input type="submit" name="submit" value="submit">
</form>
<!-- End of FORM -->
</body>
</html>
Form Page #3:
PHP Code:
<?php
require_once("x/global/api/api.php");
$fields = ft_api_init_form_page();
$params = array(
"submit_button" => "submit",
"next_page" => "thank_you_b.php",
"form_data" => $_POST,
"finalize" => true
);
ft_api_process_form($params);
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>form</title>
</head>
<body>
<!-- Start of FORM -->
<form action="<?php echo $_SERVER["PHP_SELF"]?>" method="POST">
Email: <input type="text" name="Email" value="">
<br />
<br />
Telephone: <input type="text" name="Telephone" value="">
<br />
<br />
<input type="submit" name="submit" value="submit">
</form>
<!-- End of FORM -->
/body>
</html>
Thank You Page:
PHP Code:
<?php
require_once("x/global/api/api.php");
$fields = ft_api_init_form_page();
ft_api_clear_form_sessions();
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>form</title>
</head>
<body>
Thank you.
</body>
</html>
Many thanks for the assistance.
Jeff -