Smartyのアウトプットフィルタの使い方について質問です。 出力をShift-JISに変換したいと思い、 以下のソースを書いたファイル(outputfilter.sjis.php)Smartyプラグインに追加しました。 function smarty_outputfilter_sjis($output, &$smarty){ return mb_convert_encoding($output, 'SJIS', 'UTF-8'); } 実行用のファイル(index.php)には以下のように記述しました。 $smarty = new Smarty; $smarty->compile_dir = 'templates_c'; $smarty->register_outputfilter('outputfilter_sjis'); $smarty->display('index.tpl');