Question

Looking for a way to take some html like:

  <html>
    <head>
      <style>
        *.td {
         font-weight: bold;
        } 
      </style>
    </head>
    <body>
       <div>blah blah blah</div>
     </body>
  </html>

And run it through JTidy, and keep the CSS rule in the output of the parser.

The tag is gone in the final output.

Was it helpful?

Solution 2

We had the word2000 flag set on JTidy. That is stripping the style tags.

OTHER TIPS

That's not HTML. It is a mixture of CSS and HTML. You can't expect an HTML processor to understand it the way you do.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top