[pmwiki-users] Problems with the embedded CSS in pmwiki.php
Patrick R. Michaud
pmichaud at pobox.com
Sun Nov 12 15:20:23 CST 2006
On Sun, Nov 12, 2006 at 12:53:10PM -0700, H. Fox wrote:
> On 10/27/06, Patrick R. Michaud <pmichaud at pobox.com> wrote:
> >[...] a skin that wants to
> >override the pmwiki.php embedded styles can do the following
> >in skin.php:
> >
> > global $HTMLStylesFmt;
> > $HTMLStylesFmt['skin'] = "...css overrides here...";
> >
> >These definitions will come after the pmwiki defaults, but before
> >pub/css/local.css and other administrator-defined styles.
>
> Not exactly. In testing I've discovered it won't override PmWiki
> defaults that come from stdmarkup.php, at least not in PmWiki 2.1.26
> it won't.[1]
Okay, you're correct that administator-defined styles in
the local/*.php files come before the skin's styles and
stdmarkup.php. (This is different from administrator-defined
styles in pub/css/*.css, which come later.)
I can likely change this in 2.2.0-beta so that stdmarkup styles
show up in the same location as the core styles.
> I also notice that styles from Main.php appear *after* styles from
> Main.HomePage.php. I would have expected the reverse. Is that a
> feature or a bug?
Per-page configs are processed before the group config -- i.e.,
Main.HomePage.php is processed before Main.php. This is by design,
because the reverse sequence would make it difficult for a per-page
configuration to override a per-group configuration.
(A per-page configuration that wishes to have the group configuration
take place first can trivially do so with include_once('local/Main.php') .)
Pm
More information about the pmwiki-users
mailing list