I am using php's append and prepend to put advertisements on my free hosting. I got a cheap reseller account from a friend and in the htaccess file for the accounts i added php to the following types ".htsysa" and ".htsysp" a = append, p = prepend, since the file starts with .ht most ftp programs will ignore it. Make sure you add php to the .html, .htm, etc file types so they will get the ads as well.
Originally Posted by Zach
Now here is the part that prevents the cookies and header information from causing errors. PHP has a function called "ob_start", which is basically content buffering, put this in .htsysp
And this in .htsysa
of course, you would have to make sure they know that they are not allowed to try to disable these ads, and you may want to add some randomness to them so its harder to disable them, but it is possible to do. If you have access to put the append and prepend files outside their reach, do it. Same goes for .htaccess, if you can modify httpd.conf, put em in there.
$_EANIXPREFERENCES['TextAdLocation'] = "both";
$_OUTPUT = ob_get_contents();