.name() The .name() function returns the name of a block or field. Example 4 Using .name() in a #if directive #foreach($j in $message.*) #if($j.name()=='block_A') $j.description #end #end
#foreach($j in $message.*)
#if($j.name()=='block_A')
$j.description
#end