This is a developer question: I am working on a recipe to create static HTML pages from within PmWiki. The purpose is to have a "mirror" of a wiki site as static pages to be served to the public, as the saving of dynamic PHP pages is taking too long now on the shared hosting site I am using (10 to 15 seconds for one page, compared to about 1 second for a static HTML page).
I can create a satisfactory single HTML page via a custom action, or as part of the normal page update via $EditFunctions. When I want to create multiple HTML pages in one go via another custom action, my function is calling the single-page HTML export function repeatedly, which is nearly satisfactory, but not quite. The problem is that page variables are getting evaluated only once, for the page first calling the handler function. Is there a way to make PmWiki "restart" after every page processed, to evaluate page variables fresh for every page, some kind of batch mode? I cannot see this in the code, so would be very grateful for some hints! Perhaps I can add a second question here: The exported static HTML pages are only meant for general public view, i.e. corresponding to a site visitor having "read" authorisation, not any "edit" authorisation. The page look is accordingly, without any "action" links and toolbars etc. The two custom actions for single and multiple HTML page export need "edit" or "admin" authorisation. It would be very useful, when the HTML export function is running, to have it process the page as if it is read-only, but the function is running with "edit" or "admin" authorisation. Can this be possible? This would be useful, because one would not need to insert custom conditional markup into wiki pages, to suppress the page parts which are for editors or admins only. Thanks for any input to this! I hope to release this recipe script soon, so perhaps others may find it useful. Best regards, Hans mailto:[email protected] www.softflow.co.uk _______________________________________________ pmwiki-users mailing list [email protected] http://www.pmichaud.com/mailman/listinfo/pmwiki-users
