Add CSS for better customization
nicolap - January 12, 2009 - 09:46
| Project: | Language Icons |
| Version: | 6.x-2.x-dev |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | postponed (maintainer needs more info) |
Jump to:
Description
Here a simple CSS
/* languageicons.css */
.block-locale {
padding-top: 0.1em;
text-align: right;
}
ul li.it {
background-image: none;
list-style-image: none;
list-style-type: none;
}
ul li.en {
background-image: none;
list-style-image: none;
list-style-type: none;
}Note that you must add more style using the simple naming convention, for example franch: "ul li.fr".
add this function to load them, in "languageicons.module":
/**
* Implementation of hook_init().
*/
function languageicons_init() {
drupal_add_css(drupal_get_path('module', 'languageicons') .'/languageicons.css', 'module');
}
#1
How would this allow for better customisation? None of the added CSS is specific to anything produced by Language icons and could easily be placed in any other module or theme, and so could the
drupal_add_css()call.