解析iPhone上的HTML [英] parsing HTML on the iPhone
问题描述
是否存在这样的库,或者我只是想使用正则表达式更好?
看起来像 libxml2.2
出现在SDK中, libxml / HTMLparser.h
声明以下内容:
$ b
该模块实现了HTML 4.0非验证解析器API与XML解析器兼容。它应该能够解析真实世界的HTML,即使从规范的角度来看严重破坏。
听起来像是什么我需要,所以我可能会使用它。
Can anyone recommend a C or Objective-C library for HTML parsing? It needs to handle messy HTML code that won't quite validate.
Does such a library exist, or am I better off just trying to use regular expressions?
Looks like libxml2.2
comes in the SDK, and libxml/HTMLparser.h
claims the following:
This module implements an HTML 4.0 non-verifying parser with API compatible with the XML parser ones. It should be able to parse "real world" HTML, even if severely broken from a specification point of view.
That sounds like what I need, so I'm probably going to use that.
这篇关于解析iPhone上的HTML的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!