Home >Backend Development >PHP Tutorial >求一枚正则,该怎么处理

求一枚正则,该怎么处理

WBOY
WBOYOriginal
2016-06-13 10:23:46957browse

求一枚正则
计划起飞时间:16:00 计划到达时间:19:00 候机楼:T3 状态:计划




请教正则怎么提取16:00 19:00 T3 计划 呢 谢谢了~~

------解决方案--------------------

PHP code
$str="计划起飞时间:16:00 计划到达时间:19:00 候机楼:T3 状态:计划";$str=preg_replace('/[^\da-z:\s]/i','',$str).substr($str,strlen($str)-4);//16:00 19:00 T3 计划<div class="clear">
                 
              
              
        
            </div>
Statement:
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