Difference between explode and split?
Explode Function
Explode function split a string by string
For eg
$str=”Year and Month”;
$arr=explode(”and”,$str);
this function will return an array it contains
Array{
[0]=>Year
[1]=>Month
}
Split function
split function also spliting the string by regular expressions
$str=”Year : Month”;
$arr=split(”:”,$str);
this function will return an array it contains
Array{
[0]=>Year
[1]=>Month
}
