[pmwiki-users] Suggested default template changes for 2.1
Patrick R. Michaud
pmichaud at pobox.com
Wed Dec 7 18:39:45 CST 2005
On Wed, Dec 07, 2005 at 05:27:43PM -0700, H. Fox wrote:
> On 12/7/05, Patrick R. Michaud <pmichaud at pobox.com> wrote:
> > > The Light Skin uses
> > >
> > > <link rel='stylesheet' href='$SkinDirUrl/light.css' type='text/css' />
> > > <!--HeaderText-->
> > > <link rel='stylesheet' href='$SkinDirUrl/light2.css' type='text/css' />
> > >
> > > I don't recall exactly why it was important to have both, but here's
> > > light2.css, which provides some hints.
> >
> > With the above, an admin can override the light.css settings but
> > cannot override settings in light2.css (which is overriding the
> > PmWiki defaults in <!--HeaderText-->).
>
> Exactly. IIRC the only reason I inserted the non-overridable
> selectors was to "brute force" them in. What's a better way to change
> those (.indent, .outdent, .diffbox, .diffadd code, .diffdel code,
> .diffrestore, .difftype, .difftime .diffauthor, .diffrestore) without
> using the second stylesheet?
I think a slightly better approach might be to put the following in the
skin.php file (or light.php in the case of LightSkin):
$HTMLHeaderFmt['light'] =
"<link rel='stylesheet' href='\$SkinDirUrl/light2.css' type='text/css' />";
This generates the link to the stylesheet after any PmWiki-defined styles
in the <style>...</style> section, but before any admin-generated stylesheets
coming from pub/css/ . It also opens up other possibilities for the admin
to control the sequencing of stylesheet loading (e.g., by explicitly
loading scripts/skins.php and then adding more values to the $HTMLHeaderFmt
array).
Pm
More information about the pmwiki-users
mailing list