[pmwiki-users] Preview doesn't resolve page text variables
pbowers at pobox.com
Tue May 26 23:29:46 CDT 2009
On Tue, May 26, 2009 at 8:53 PM, Patrick R. Michaud <pmichaud at pobox.com>wrote:
> I'm willing to entertain patches that make it possible to view page
> text variables when a page is being previewed, but the fact that
> it doesn't work now isn't exactly a bug in my book.
It seems like the only "sure-fire" way to deal with any and all issues
related to preview processing would be to patch the pagestore Read()
function. However, this is going to cause a performance hit throughout all
operations and seems very not worth it.
However, to fix the specific issue raised by Randy it could suffice to patch
PreviewPage(), adding these:
Then CachePTV() needs to be defined by splitting up PageTextVar() so that
PageTextVar() reads the page, calls CachePTV() with the $page read, and then
returns from the cached values. CachePTV() itself would be the code from
PageTextVar() which processes the $page and caches.
I'm happy to code up a patch if it's likely to be used in core, but it
doesn't lend itself to a recipe and so is pointless unless it will be
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the pmwiki-users