Overriding CSS

(Update) Later, switched to creating a subtheme because of a limitation of this method

Looked around, and it looks fine mostly, except that those double border around codes displayed by GeShi filter. Using chrome’s “Developer tools” (which actually was my first experience, and it seems like it’s great and indispensable tool for creating homepage), I found that it is made up of <div class="geshifilter">, <pre>, in that order, and

  1. geshifilter defines the border of div.geshifilter,
  2. drupal theme defines the border of pre,

so, it become double bordered.

Decided to solve it by adding CSS to already created module. First, create moonz.css in the module’s directory.

div.geshifilter pre {
  border: none;
}

Add the following PHP code to moonz.module.

function moonz_init() {
  drupal_add_css(drupal_get_path(‘module’, ‘moonz’) . ‘/moonz.css’);
}