Home > Backend Development > PHP Tutorial > 排除字符串里某字符第3次出现后面的所有字符,代码如何写

排除字符串里某字符第3次出现后面的所有字符,代码如何写

WBOY
Release: 2016-06-13 11:33:26
Original
913 people have browsed it

排除字符串里某字符第3次出现后面的所有字符,代码怎么写
排除字符串里某字符第3次出现后面的所有字符,代码怎么写

比如字符串“2你好2哈哈2对的啊哈哈哈”

就是排除第3个2后面的所有字符得到结果“2你好2哈哈2"

请知道的大哥直接给代码好吗谢谢了 

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template