I have a snippet of html containing some php short tags that I am returning via file_get_contents(). The problem with this is that PHP returns the short open tags inside of the document without parsing them as php. What is the best way to go about getting returned html to evaluate the php inside of it?
I have tried
echo eval('?>'.file_get_contents('/path/to/file.html'));
and this works, but php docs discourage the use of eval for obvious reasons.