リンクをob_get_contents()に置き換えようとしていますが、別の関数を使用してタイトルなどのヘッドタグを置き換えています...このコードでは、ヘッダー、インデックス、フッターが二重になります。
関数
function self_urls_convert($html) {
$html = str_replace('index.php','index',$html);
$html = str_replace('about_us.php','about_us',$html);
return $html;
}
フッター
$output = ob_get_contents();
if (ob_get_length() !== FALSE){
ob_end_clean();
}
echo self_urls_convert($output);
echo $tags->handle_output($output);
if (ob_get_length() !== FALSE){
ob_end_flush();
}