[TYPO3-project-formidable] Why are the template methods ifEmpty / ifNotEmpty commented out?
Hauke Hain
newgrp at googlemail.com
Sun Mar 8 15:27:22 CET 2009
Ok,
I think I know why.
case "ifNotEmpty": {
if(tx_ameosformidable::templateDataAsString($mData) === "") {
return TRUE;
}
return $mData;
break;
}
If TRUE is returned the part that is empty is shown.
And if you set it to FALSE:
case "ifNotEmpty": {
if(tx_ameosformidable::templateDataAsString($mData) === "") {
return FALSE;
}
return $mData;
break;
}
It works like it should, but a JavaScript exception arises.
Can you fix this problem or tell me how I can achieve that a part of the
template is only shown if
storedData("dbfield") is not empty?
Now I use:
<!-- ###storedData("backup").ifNotEmpty() perimeter### begin-->
But also
<!-- ###storedData("backup").isTrue() perimeter### begin-->
would be possible if isTrue would use "==" instead of "===", but thats not
really a solution...
Kind regards,
Hauke
More information about the TYPO3-project-formidable
mailing list