Search code examples
htmlcssstylesheet

Override internal stylesheet with external stylesheet, without editing html


I use Joomla 2.5 and I'd like to override the features of a module which's CSS is actually embedded within the tag of the html pages the module is on. So in essence, it uses an internal style sheet. I'd like to override that stylesheet without editing the html, as I cannot edit the html pages because these are produced through joomla.

However, I can edit Joomla's external template stylesheet to add style. So my question is, how do I orveride the internal stylesheet with the external stylesheet.

is this possible?

Just produce an example please and I will fill in the blanks myself as I am well knoweldged in CSS and html.

Thank you.


Solution

  • You could try to use the CSS !important construct to override internal stylesheets.

    See jsFiddle for an example:

    <p style="color: red;"> this is a test</p>
    

    Will be displayed using a different color if you specify CSS as

    p {color: #00ff00 !important;}