#264 Finer control over appearance using CSS.


I was asked by my employer to make a company theme for
webmail to match that of our web site (or close to it).

The problem is that handling of "themes" is NOT managed
with a .css file (at least not entirely). There are no
"class=" attributes on BODY, TD, TABLE, etc. tags. For
example it would have been better to specify on the
mailbox listing

<td class="even">
<td class='odd'>

to control alternating colours of the rows. If a CSS
class is not defined, its ignored by Mozilla, IE, and
Opera. The whole theme management would be better
served through the correct application of class
attributes through out.

However in order to achieve the minimum required for my
firm's needs, I only modified two files: src/login.php
and src/left_main.php.

The small patch below permits severals things:


Customisation of the entire look of the login screen
through the creation of a company login plugin in
conjunctions with a company .css file that uses:

a) the login_cookie hook to specify a $theme_css and
set some new variables to disable display elements
b) login_top to insert HTML before the form
c) login_bottom to insert HTML after the form

It also adds to the BODY tag: class="LoginBody" With
the CSS class LoginBody, I can specify style attributes
like "background-image" in the .css file.


The patch adds to the BODY tag: class="LeftMainBody" ,
which again allows the a .css file to specify
interesting style settings like "background-image"
(again) and then in conjuction with a company theme
that hooks left_main_before and left_main_after, HTML
can be inserted to wrap the folders list.

I would appreciate if the Squirrel Mail team would
consider adding this patch to the current stable branch
and incorporate these changes into the development branch.


  • Anthony Howe

    Anthony Howe - 2003-01-06

    example: plugins/tas_login/setup.php

  • Anthony Howe

    Anthony Howe - 2003-01-06

    Logged In: YES

    I'm also including examples of how these patches were used
    by us.

  • Anthony Howe

    Anthony Howe - 2003-01-06

    example: themes/tas-theme.php

  • Anthony Howe

    Anthony Howe - 2003-01-06

    example: themes/css/tas.css

  • Anthony Howe

    Anthony Howe - 2003-01-06

    Replacement for sm-1.2.10.patch (fix typo).

  • Thijs Kinkhorst

    Thijs Kinkhorst - 2003-01-07

    Logged In: YES

    Thanks for the patch. Users who want to can use this on
    their setup, but I'm not integrating since we're planning to
    implement templating.

  • Thijs Kinkhorst

    Thijs Kinkhorst - 2005-04-06
    • priority: 5 --> 1

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks