mirror of
https://github.com/e107inc/e107.git
synced 2025-07-12 10:36:20 +02:00
Added 'autoplay' and 'controls' support to the toAudio() method.
This commit is contained in:
@ -4792,7 +4792,10 @@ class e_parser
|
|||||||
|
|
||||||
$mime = varset($parm['mime'], 'audio/mpeg');
|
$mime = varset($parm['mime'], 'audio/mpeg');
|
||||||
|
|
||||||
$text = '<audio controls style="max-width:100%">
|
$autoplay = !empty($parm['autoplay']) ? "autoplay " : "";
|
||||||
|
$controls = !empty($parm['controls']) ? "controls" : "";
|
||||||
|
|
||||||
|
$text = '<audio controls style="max-width:100%" '.$autoplay.$controls.'>
|
||||||
<source src="'.$file.'" type="'.$mime .'">
|
<source src="'.$file.'" type="'.$mime .'">
|
||||||
Your browser does not support the audio tag.
|
Your browser does not support the audio tag.
|
||||||
</audio>';
|
</audio>';
|
||||||
|
Reference in New Issue
Block a user