摘要: $words = ["我", "你", "他", "她"];//过滤库 $sentence = "我和你一起去他家找她";//待过滤的句子 foreach($words as $word)//遍历过滤库的词 { $len = strlen($word);//获取过滤词的长度 $pos = strpos($sentence,$word);//寻找过滤词的位置 $sentence = substr_r 阅读全文
posted @ 2019-10-27 16:18 岁月必然的流逝 阅读(1284) 评论(0) 推荐(0) 编辑