- substr: documentation ( source)
- strpos: documentation ( source)
- print_r: documentation ( source)
<?php
$type = '';
$index = -1;
$t = "audio/x-wav-chunk; index=10";
$_p = strpos($t, ';');
if ($_p !== false)
$type = substr($t, 0, $_p);
print_r($type);