I have a PHP function that I\'m using to output a standard block of HTML. It currently looks like this:
Create a template file and use a template engine to read/update the file. It will increase your code's maintainability in the future as well as separate display from logic.
An example using Smarty:
Template File
{$title}
{$string}
Code
function TestBlockHTML(){
$smarty = new Smarty();
$smarty->assign('title', 'My Title');
$smarty->assign('string', $replStr);
return $smarty->render('template.tpl');
}