better support for page caching (major performance fix)