I know this is an old question ... but I think it's worth noting that you can do something like:
$content = '
<?php if($var=true): ?>
print this html
<?php endif; ?>
';
This would usually be very cumbersome to evaluate, but you can do:
include "data://text/plain;base64,".base64_encode($content);
And he will understand so quickly!