PHP Array with multiple lines -
i have array looks illustration below. how value in first line (the sound file path)? have tried array_rand()
gives me values letter letter. sorry if has been answered before, couldn't find myself. in advance.
array ( [0] => path/to/audiofile.mp3 3500440 audio/mpeg [1] => path/to/anotheraudiofile.mp3 5661582 audio/mpeg ... )
edit: var_dump gives me this:
array(2) { [0]=> string(98) "path/to/audiofile.mp3 3500440 audio/mpeg " [1]=> string(95) "path/to/anotheraudiofile.mp3 5661582 audio/mpeg "
}
have tried split on line homecoming ?
$tmp = explode(php_eol, $myarray[0]); $tmp = explode('"', $tmp[0]); $path = $tmp[1];
php arrays
No comments:
Post a Comment