+ 2
I am not getting how to add audio in html5 from the android phone.Can anyone help me?
I tried many times but i can't add the audio in html5
27 Respostas
+ 3
kartik dhingra if you want to play your audio file from your phone here on slololearn the audio must be hosted online,
Options:
1 either you browse the audio file on google, and copy the url an paste in your code here.
2: download Dropbox app, tap on the audio share option on your phone, and select with dropbox after the upload is completed navigate to the file on dropbox and copy the url and paste in your code.
But the code you wrote will only work on your PC and not on sololearn
+ 4
<audio controls>
<source src="audio.mp3" type="audio/mpeg">
<source src="audio.ogg" type="audio/ogg">
</audio>
+ 3
In phone, go to your audio. Then tap on that audio and hold, show you options, then go to properties or more, then go to details, search for locations, then tap and hold on locations, select all and copy, then paste in your code
+ 3
Var audio= new Audio("file name") ;
Audio. Play() ; // in js
+ 2
Change audio name with your audio file name, and there is two type of audio extension file in this code if you dont need second one you can delete it
+ 2
Your code is ok i think. But I'm pretty sure that your audio link is wrong
+ 2
Do you using phone for code?
+ 2
In laptop or pc, go to your audio folder, right click on audio and choice properties, then search for locations, then with mouse select location address and copy in your code
+ 2
Yes you can do this but you need to keep it in your mind that same folder names and file names you should copy and paste for your file or code dont work
+ 2
He said in html5.
+ 2
You may find answer in https://pupunzi.open-lab.com/2013/03/13/making-html5-audio-actually-work-on-mobile/,
+ 1
Send here your code
+ 1
Ok just a minute
+ 1
I am confused in that only.
Can you guide me how to get audio link in my file manager
+ 1
Yes
+ 1
I tried in laptop also
+ 1
<audio control> <source src="file.name" type="audio/mpeg"> </audio>...if not working then ur browser is not supporting this audio tag
+ 1
<audio></audio>
+ 1
Try it ,if it is the right location or just download dropbox ,upload audio on it and copy the link to paste it in your file