Issue
This had me troubling for quite a while and looking on the Internet didn't really give any real solutions (here and here).
In my case the errors were caused by a custom Web Service that I added to SharePoint. When one of the Web Parts called the Web Service an event log entry was written:
Event Type: Error
Event Source: Office SharePoint Server
Event Category: Publishing Cache
Event ID: 5785
Date: 29/01/2007
Time: 11:58:36
User: N/A
Computer: VPC-WS03
Description:
Unable to connect publishing custom string handler for output caching. IIS Instance Id is '238027762', Url is 'http://localhost/_myws/Service1.asmx'.
Solution
The solution is to modify the web.config of the Web Service application. Remove the PublishingHttpModule module that was added by the root web.config:
...
Applies To
MOSS 2007 (because the problem relates to Publishing)