Jul 1st, 2011, 7:29 AM
Heya,
Ah! On your very first page, you need to put this block of code at the very top, before the opening DOCTYPE.
The reason is that the ft_api_process_form() function actually redirects from one page to the next, but it can only do so if nothing's been output to the browser when it's called.
- Ben
Ah! On your very first page, you need to put this block of code at the very top, before the opening DOCTYPE.
Code:
<?php
require_once("formtools/global/api/api.php");
$fields = ft_api_init_form_page("", "test");
$params = array(
"submit_button" => "submit_order1",
"next_page" => "choose-image.php",
"form_data" => $_POST
);
ft_api_process_form($params);
print_r($fields);
?>
The reason is that the ft_api_process_form() function actually redirects from one page to the next, but it can only do so if nothing's been output to the browser when it's called.
- Ben