Re: [webmin-devel] Some changes for better themes.
Jamie Cameron <[email protected]>
| Newsgroups | gmane.comp.web.webmin.devel |
|---|---|
| Message-ID | <[email protected]> |
On Wed, 2005-05-04 at 13:38, Eldy wrote:
> Is it possible to replace in all webmin code the following strings
> <input type=button
> by
> <input class=button type=button
>
> and also
> <input type=submit
> by
> <input class=button type=submit
>
> Such a change should be safe and can be done by a recursive replace in all webmin .pl files.
> It will allows theme developpers to add a more personalised look in theme (by adding on
> buttons a different css style, for example a 3D style from a picture, using the "button" class).
> This is for the moment not possible because if doing this by using the "input" class,
> all other input fields (like input=text) are also affected.
>
> This is to have themes that looks nicer than it is possible to do now.
I am actually in the process of replacing all the code that simply
prints out HTML for form inputs with calls to a function, which can be
overridden by a theme. So code like :
print "<input type=submit name=ok value='Click Me'>\n";
is being replaced with :
print &ui_submit("Click Me", "ok"),"\n";
Your theme will then be able to define a function call theme_ui_submit
in it's theme.pl file, which will override ui_submit and can return
whatever HTML you like for the button.
Not all modules use these new functions yet, but some (like Logrotate
and IPFilter) do ..
- Jamie
-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games.
Get your fingers limbered up and give it your best shot. 4 great events, 4
opportunities to win big! Highest score wins.NEC IT Guy Games. Play to
win an NEC 61 plasma display. Visit http://www.necitguy.com/?r=20
-
Forwarded by the Webmin development list at [email protected]
To remove yourself from this list, go to
http://lists.sourceforge.net/lists/listinfo/webadmin-devel