Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

preg_split in php

$str = "a. Hello my name is xxx.
b. Hello is my name yyy?
c. Hello my name is rrr!
d. Hello my name is aaa";
$res = preg_split("/
[a-z].s/", "
" . $str);
array_shift($res);
print_r($res);

output

Hello my name is xxx.
Hello is my name yyy?
Hello my name is rrr!
Hello my name is aaa
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #php
ADD COMMENT
Topic
Name
6+2 =