[Pmwiki-users] Page caching
Paweł Różański
pawel.rozanski
Wed Jan 5 16:31:02 CST 2005
I'm aware of that problems. My wiki is simple one so...
> For example, would the RecentChanges page be served correctly?
added @unlink("wiki.c/$rcname"); to PostRecentChanges function, works
like a charm.
> What about a page that has an (:include:), (:if cond param:), or
> (:pagelist:) directive on it? The included page might have changed, the
> condition might be different, or the pagelist could be longer.
I don't use that construct so far, so i just ignored that case, but
added one "if" so my Search page isn't cached at all.
However there is a problem even for my small wiki:
If i see a link on page A to page which don't exist (B).
A is cached, so if i create some content on B, A still shows link to
B?action=edit
Right now, i added to PostPage an @exec("./delref $pagename"); delref
is an ugly bash script. It does
cd wiki.c
rm -v `grep -m 1 -s -H "${1/.//}?action=edit" * | cut -d ':' -f 1`
so it seeks pages (in cache dir) with "B?action=edit" and deletes them
I know, that is even more hacked way to do that, but it works and i
suppose grep is faster than doing that by hand in PHP.
I done that, because i use a small webserver and it works for me
(maybe not so pretty) I just wanted to inspire owners of small wikis
to experiment
a werid one,
Pawel
More information about the pmwiki-users
mailing list