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
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
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
Bug Report: Empty textarea fields shown in email templates - Printable Version

+- Form Tools (https://forums.formtools.org)
+-- Forum: Form Tools (https://forums.formtools.org/forumdisplay.php?fid=1)
+--- Forum: General Discussion (https://forums.formtools.org/forumdisplay.php?fid=5)
+--- Thread: Bug Report: Empty textarea fields shown in email templates (/showthread.php?tid=2244)



Bug Report: Empty textarea fields shown in email templates - flip3 - Oct 24th, 2012

Hello,

When I define a field as textarea field and it is empty, it still shows up in the email template when using this code:

Code:
{if $ANSWER_accommodation_description}Description: {$ANSWER_accommodation_description}
{/if}

Additionally, it adds two line breaks after the field instead of one in the case of other field types. I solved this now by using simply this code (not sure if that's ok):

Code:
{if $ANSWER_accommodation_description}Description: {$ANSWER_accommodation_description}{/if}

I was also trying to use double if-tags in email templates which produced an error. Is there another chance to show a block of information only if a specific condition matches? In my case it should be that the airport_transfer field value should match with "yes":

Code:
{if $ANSWER_airport_transfer=yes}### TRANSFER ###
{if $ANSWER_transfer_name}Name: {$ANSWER_transfer_name}
{/if}
{if $ANSWER_transfer_phone}Phone: {$ANSWER_transfer_phone}
{/if}
{if $ANSWER_transfer_description}Description: {$ANSWER_transfer_description}
{/if}{/if}

Many thanks,

Philip


RE: Bug Report: Empty textarea fields shown in email templates - kwhitlock - Oct 29th, 2012

If you do a character count on a LARGE TEXT field, even though it may be NULL the count returns as 10. If there are characters in that field, the character count is 10 + length of the string. I would think this is a bug. I am facing the same problem. For the fields that are <256, the count returns fine.

try {$nameOfField|count_characters:true}



RE: Bug Report: Empty textarea fields shown in email templates - flip3 - Nov 4th, 2012

Hello,

Thanks for your feedback. I tried both:

{if $ANSWER_school_schedule|count_characters:true}Your schedule: {$ANSWER_school_schedule}
{/if} -> Doesn't change anything.

{if $ANSWER_school_schedule}Your schedule: {$ANSWER_school_schedule|count_characters:true}
{/if} -> Show the character count which is "80" in my case instead of the field content.

Philip


RE: Bug Report: Empty textarea fields shown in email templates - kwhitlock - Nov 4th, 2012

So is this a bug or not? I am still confused to the count of characters in a textarea.


RE: Bug Report: Empty textarea fields shown in email templates - flip3 - Nov 5th, 2012

For me it's a bug but I'm not a developer. The Form Tools team has to advice ...