我正在接收来自套接字的消息,并写入它的html日志。我需要在消息中搜索任何类型的urls,并检索列表并将其替换为foo。
发布于 2010-10-03 16:51:49
找到许多regular expressions for a URL中的一个并使用QString::replace (正则表达式重载)。
QString s;
QRegExp regexp(...);
s.replace(regexp, "foo");https://stackoverflow.com/questions/3849003
复制相似问题