Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
在匹配的情况下,您认为哪种方案更好?
是eregi还是stripos或任何其他方法?
这取决于您是要进行完全匹配还是正则表达式匹配。
此外,eregi已被弃用,它不是二进制安全的,并且不适用于 UTF-8。对于正则表达式匹配,您应该使用preg_match与iflag 代替。
i