Forum OpenACS Q&A: Response to adp code not being parsed properly
I expect that the reason it "works" on some requests but not on others would be because different requests end up hitting different threads, and each thread has it's own Tcl interpreter, and in one (or more, but not all) of them the internal state of the templating engine has gotten corrupted/messed up.
Does the .adp/.tcl pair rely on database queries? Do you have a staging server you can test it on? If so, does the same .adp exhibit the same behavior? Can you reduce/simplify the template down to some minimal example? If you don't have another system to test it on, and you want to email the .tcl & .adp code to me, I'd be happy to give it a try on our system.
Also, if you are running AOLserver 3.0, you really ought to upgrade to either 3.3+ad13 or 3.4. Prior versions have security vulnerabilities.