Remove HTML Tags from an NSString on the iPhone

前端 未结 22 1636
心在旅途
心在旅途 2020-11-22 10:02

There are a couple of different ways to remove HTML tags from an NSString in Cocoa.

One way is to render the string into an

22条回答
  •  生来不讨喜
    2020-11-22 10:38

    I would imagine the safest way would just be to parse for <>s, no? Loop through the entire string, and copy anything not enclosed in <>s to a new string.

提交回复
热议问题