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 "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
Great Module - Printable Version

+- Form Tools (https://forums.formtools.org)
+-- Forum: Modules / Other (https://forums.formtools.org/forumdisplay.php?fid=8)
+--- Forum: Modules (https://forums.formtools.org/forumdisplay.php?fid=16)
+--- Thread: Great Module (/showthread.php?tid=4)



Great Module - stevenheidel - Jan 11th, 2009

I have been waiting for this module for a long time Smile But how do I actually use it?


RE: Great Module - Ben - Jan 12th, 2009

Haha :-) Yes, documentation would sure be nice - especially for this module.

I'll add some documentation on this today or tomorrow. But in brief, the key lies around the idea that you can modify the contents of the $_POST variable right in the rules. You have free reign to do whatever you want to the POST info - it all happens prior to adding to the database & sending the emails.

So, for example, if you had a phone number field organized in three separate input fields in your form, you could combine them by creating a rule with the following PHP:

PHP Code:
if ( (isset($_POST["phone_1"]) && !empty($_POST["phone_1"])) && 
     (isset(
$_POST["phone_2"]) && !empty($_POST["phone_2"])) && 
     (isset(
$_POST["phone_3"]) && !empty($_POST["phone_3"])) )
{
  
$_POST["phone"] = "{$_POST["phone_1"]}-{$_POST["phone_2"]}-{$_POST["phone_3"]}";


Then, through the FT UI, you could create a new database field with the form field name "phone". This combined info of the 3 phone fields would then appear as a single field in the UI. Handy as hell, but this is just one example.

The module also has other features, like letting you set a variable (I forget the name...) which tells FT not to process the submission - but behave like it processed it normally. This should be handy for handling spam. I'll be sure to include that in the documentation.

I'll also release an update today or tomorrow, so that it uses CodeMirror - the syntax highlighter. That should make adding/editing the PHP code in the UI slightly less urksome.

All the best -

Ben