I’m making a websites with some audiofiles.
So now I’m a bit stuck.
I have to create a formula that converts f.ex; 3:11 into milliseconds.
Should I use a while loop to do that?
<category id="cat2"/>
<thumbnail url="admin/imgsupl/<? echo $row["thumbnail"]; ?>" />
<pdf url="admin/docsupl/<? echo $row["filedownload"]; ?>" />
<video url="admin/docsupl/alixir.flv" title="Alixir video"/>
<?
$ThisFileInfo = $getID3->analyze("../admin/docsupl/".$row["voice_over_mp3"]);
getid3_lib::CopyTagsToComments($ThisFileInfo);
$ThisFileInfo['playtime_string']; //3:11
?>
I can’t manage to find an exact formula as well…
Thanks
You can split the string by “:”, and then you’ll have minutes in one var and seconds in another. You then convert both of them to integers and multiply: