【发布时间】:2019-03-21 07:37:55
【问题描述】:
我有以下字符串。
"Christmas is a very expensive> time of year for most> people so the <br/>Christmas> bazaar is an <b>opportunity</b> for parents to indulge their offspring and buy lots> of small items> as either presents or <b>stocking fillers</b> .|Trust me, it's not easy scooping up gift votives and <b>stocking stuffers</b>"。
现在我只想从以单词结尾的字符串中删除">",而不是像"<br/> or <b"这样的html标签
如果我使用String.replace("\\>",""),那么它会从字符串中删除所有> 标签。
如何做到这一点?
【问题讨论】:
-
如果您提供一个完整的示例文本来显示正在被删除的误报将会很有帮助。
-
也加入预期的输出。