akfred
How can I open or download mp3 files from view page
Create a custom view and use ViewEntry in your Infolist
ViewEntry::make('audio')
->viewData([
'audio' => $infolist->record->audio
])
->view('infolists.components.audio-view')
//in your infolists.components.audio-view.blade.php add this code
<audio controls>
<source src="{{$audio}}" type="audio/mpeg">
</audio>
21 replies