|
Posted by Ivo Jansch on 10/15/60 11:27
Hi,
thomas Armstrong wrote:
> But when analyzing my HTTP headers, I get:
> --------
> * Content-Type = text/html; charset=ISO-8859-1
> --------
> What am I doing wrong? Thank you very much.
The problem is that your function is executed only during the initial
rendering of the page. When the page is cached, your function is no
longer executed, and the header no longer output.
If you want to change the headers, it's better not to put them in your
template, but before your call to smarty->fetch, like so:
<?php
....
header("Content-type: text/html; charset=utf-8");
$smarty->display("index.tpl");
?>
There's not much reason to put the header inside the template, neither
from a template designer perspective nor functionality wise, I think.
Greetings,
Ivo
[Back to original message]
|