View Single Post
Old 12-03-2016, 08:32 PM   #1
roger64
Wizard
roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.
 
Posts: 2,625
Karma: 3120635
Join Date: Jan 2009
Device: Kindle PW3 (wifi)
Getting rid of inline styles

Hi

Using Sigil regex engine, I do not succeed to eradicate this kind of inline styles that one may find for example in the head part of some xhtml files:

Spoiler:

Code:
 <style type="text/css">

  /*<![CDATA[*/

  p.sgc-9 {font-size:92%}
  span.sgc-8 {font-size:70%;vertical-align:super}
  span.sgc-7 {font-style:italic;font-size:92%}
  span.sgc-6 {font-style:italic}
  span.sgc-5 {font-size:92%}
  span.sgc-4 {font-size:133%}
  h1.sgc-3 {page-break-before:always}
  span.sgc-2 {font-size:108%}
  span.sgc-1 {font-size:150%}

  span.sgc-10 {font-weight: normal;}
  /*]]>*/
  </style>


I tried with:
Code:
<style type="text/css">(.*?)</style>
in regex mode with DotAll to no avail. Maybe the CDATA make a problem?

There must be a way

EDIT: My "problem" was a faulty selection of files. SOLVED. Sorry for this.

Last edited by roger64; 12-03-2016 at 08:39 PM. Reason: solved
roger64 is offline   Reply With Quote