How to Show Conditional Content Blocks

Content blocks can be shown via an IF ELSE statement, but the trick is to store the block in a variable, and then render the variable.

%%[
var @myBlock, @myVariable
IF @myVariable == "TRUE" THEN
   SET @myBlock = ContentBlockByID("1234")
ELSE
   SET @myBlock = ContentBlockByID("5678")
ENDIF
]%%

%%=v(@myBlock)=%%