Tels wrote:
Here is a snippet from DynamicPageList2:
// The callback function for converting the input text to HTML output function DynamicPageList2( $input ) { ...
[snip]
$wgOut->addMeta("http:Pragma", "no-cache"); ...
When I add $wgOut->addScript( "<style>....</style>" ); here, would that add the style to every page in the wiki, or only pages that have a <DPL> tag on it (which triggers that extension).
That would only add the style when the <dpl> tag gets parsed and rendered; it looks like a bug in the extension code.
It would, for instance, *not* add the style when the page containing the tag is shown if the HTML is pulled from the parser cache (as it would be, most of the time.)
As for the cache, I don't intent to do the "no-cache" etc, so, if I added AddScript(), would the added style get cached or would it disappear when someone views a cached copy?
It would disappear.
(You could make a custom skin which works this way.)
But that would change all pages. What I want to achive is that everypage is normal, even the first page of a presentation (the table of contents), and when you switch to the second one, only the navigation box remains and the menu etc disappears, making more space available for the actula slide.
Let me be more specific. :) You could make a custom skin which responds to the custom signals you add in your extension.
-- brion vibber (brion @ pobox.com)