The following warnings occurred:
Warning [2] Undefined array key "avatartype" - Line: 783 - File: global.php PHP 8.1.31 (Linux)
File Line Function
/global.php 783 errorHandler->error
/printthread.php 16 require_once
Warning [2] Undefined array key "avatartype" - Line: 783 - File: global.php PHP 8.1.31 (Linux)
File Line Function
/global.php 783 errorHandler->error
/printthread.php 16 require_once
Warning [2] Undefined variable $newpmmsg - Line: 40 - File: global.php(841) : eval()'d code PHP 8.1.31 (Linux)
File Line Function
/global.php(841) : eval()'d code 40 errorHandler->error
/global.php 841 eval
/printthread.php 16 require_once
Warning [2] Undefined array key "style" - Line: 909 - File: global.php PHP 8.1.31 (Linux)
File Line Function
/global.php 909 errorHandler->error
/printthread.php 16 require_once
Warning [2] Undefined property: MyLanguage::$lang_select_default - Line: 5024 - File: inc/functions.php PHP 8.1.31 (Linux)
File Line Function
/inc/functions.php 5024 errorHandler->error
/global.php 909 build_theme_select
/printthread.php 16 require_once
Warning [2] Undefined array key "additionalgroups" - Line: 7162 - File: inc/functions.php PHP 8.1.31 (Linux)
File Line Function
/inc/functions.php 7162 errorHandler->error
/inc/functions.php 5044 is_member
/global.php 909 build_theme_select
/printthread.php 16 require_once
Warning [2] Undefined array key 1 - Line: 1415 - File: inc/functions.php PHP 8.1.31 (Linux)
File Line Function
/inc/functions.php 1415 errorHandler->error
/inc/functions.php 1370 fetch_forum_permissions
/printthread.php 76 forum_permissions
Warning [2] Undefined array key "showimages" - Line: 160 - File: printthread.php PHP 8.1.31 (Linux)
File Line Function
/printthread.php 160 errorHandler->error
Warning [2] Undefined array key "showvideos" - Line: 165 - File: printthread.php PHP 8.1.31 (Linux)
File Line Function
/printthread.php 165 errorHandler->error
Warning [2] Undefined array key "showimages" - Line: 160 - File: printthread.php PHP 8.1.31 (Linux)
File Line Function
/printthread.php 160 errorHandler->error
Warning [2] Undefined array key "showvideos" - Line: 165 - File: printthread.php PHP 8.1.31 (Linux)
File Line Function
/printthread.php 165 errorHandler->error



Form Tools
namespace: if used, how to clear session (and remove uncompleted sessions) - Printable Version

+- Form Tools (https://forums.formtools.org)
+-- Forum: Form Tools (https://forums.formtools.org/forumdisplay.php?fid=1)
+--- Forum: API (https://forums.formtools.org/forumdisplay.php?fid=17)
+--- Thread: namespace: if used, how to clear session (and remove uncompleted sessions) (/showthread.php?tid=2246)



namespace: if used, how to clear session (and remove uncompleted sessions) - chuanse - Oct 25th, 2012

Hi,

I am using namespace in my external form, processed with the API.

When I reach the last page I get a 306 error. I suppose I should edit the values of the last lines in the code according to the ft_api_init_form_page values:

Code:
require_once("/home/tandform/public_html/formtools/global/api/api.php");
//$fields = ft_api_init_form_page();
$fields = ft_api_init_form_page("", "live", "tandform");
$params = array(
  "no_sessions_url" => "index.php"
    );
ft_api_process_form($params);
ft_api_clear_form_sessions();
ft_api_delete_unfinalized_submissions(1, true);

Should I add something to the clear_form ?
To what do I change the delete_unfinalized_submissions?
For those with the same issue: I found one answer already:

Quote:If you originally passed a custom sessions namespace string to the ft_api_init_form_page function, you need to pass the same namespace string to this function. For example, if your namespace was "my_form", you'd call this function like so:

Code:
ft_api_clear_form_sessions("my_form");



RE: namespace: if used, how to clear session (and remove uncompleted sessions) - chuanse - Oct 26th, 2012

Argh, graveyard shift bonehead mistake

of course the process form shouldn't be there the last page :/

correct code in my case is:

Code:
require_once("/home/tandform/public_html/formtools/global/api/api.php");
$fields = ft_api_init_form_page("", "live", "tandform");
ft_api_clear_form_sessions("tandform");
ft_api_delete_unfinalized_submissions(1, false);

I still am trying to figure out why the no_sessions_url parameter is not working with php form validation :/
http://forums.formtools.org/showthread.php?tid=2245&action=lastpost

Does anyone know what do to with that?