PHP | How to convert a string to an array?
string to array
There is a function in PHP called explode() which is used to convert any string to an array.
<?php $str = "Hello world. It's a beautiful day."; print_r (explode(" ",$str)); ?> // Output will be Array (  => Hello  => world.  => It's  => a  => beautiful  => day. )