可能重复: 为某些单词测试字符串的有效方法
我想检查字符串是否包含以下任何单词:ban,bad,user,pass,stack,name,html.
如果它包含我需要回答的坏词数量的任何单词
str = 'Hello my name is user';
php
php ×1