Active
Project:
Page Preview
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
30 Mar 2012 at 11:39 UTC
Updated:
3 May 2013 at 16:38 UTC
Jump to comment: Most recent file
Hello,
Pagepreview (which is a great module btw) use the cache_page table for storing the temporary node data to be displayed by the iframe.
The problem is that cache_page is meant to store actual rendered pages, and as such, some modules will alter its behavior for page caching purpose, and break the pagepreview functionnality.
For example, the varnish module will take over the caching of cache_page, and it is designed to cache nothing in the cache_page table if you calls cache_set on cache_page.
A patch follows.
| Comment | File | Size | Author |
|---|---|---|---|
| #1 | pagepreview-new-cache-table-1509512.patch | 1.59 KB | ndeschildre |
Comments
Comment #1
ndeschildre commentedThe attached patch makes pagepreview create its own cache table, and also delete the cached data right after its use.
Also, a quick check was added to avoid warnings with invalid tokens.
Comment #2
bethhauck commentedThe cache_clear_all statement in this patch erases the preview before it can be rendered, but it works perfectly if you comment that out. Maybe it just needs to be called later.
Comment #3
les limCommitted to 7.x-1.x. Thanks, ndeschildre.
I couldn't replicate the problem identified in #2. Please re-open this if it remains an issue.
Comment #5
ericras commentedIs creating a new cache bin (and table) necessary? Removing the use of 'cache_page' was the right idea and needed but can't the basic 'cache' be used instead of a custom 'cache_pagepreview'?