Make NSXMLParser skip element

I am using NSXMLParser in an iPhone application to parse HTML files to link to RSS or Atom.

Everything works fine until the parser finds an element <script>that includes Javascript code without a CDATA declaration, this will result in a Parse error.

Can you tell the parser to skip all elements with a name <script>?

+3
source share
2 answers

Why not just implement the parser: parseErrorOccured: and say that it fails? I do not believe that there is a way to say "skip this element"

0
source

, . , .

, , Tidy, .

0

Source: https://habr.com/ru/post/1725800/


All Articles