0

I am playing mp3 files on the JW player but i am facing a strange problem. JW player is playing mp3 files having mime type "audio/mpeg" but it is failed to play mp3 files having mime type "audio/x-mpeg". It is such a strange problem for me because both files are mp3 JW player should play both.

I have also tried to convert mp3 file to mp3 file using ffmpeg in php but it is still producing mp3 file having mime type "audio/x-mpeg". exec(ffmpeg -i $input_file -vn -ar 44100 -ac 2 -ab 192k -f mp3 output.mp3)

one thing i need to mention that this file type is generating from ios app. I am stuck from 2 days in this issue. Your help would be really appreciated . Thanks

john
  • 611
  • 1
  • 7
  • 33
  • Show the complete log/console output from the `ffmpeg` command. – llogan Feb 22 '17 at 19:06
  • why `audio/x-mpeg` mime type ? – Hitesh Feb 24 '17 at 09:39
  • @LordNeckbeard I am executing ffmpeg command in php as i have posted it in the answer . I am not executing ffpmeg command on console. – john Feb 24 '17 at 11:30
  • @Hitesh i am recording audio on ios app and its audio is generating in mp3 and its mime type is audio/x-mpeg . I have tried to convert this mp3 using ffmpeg but still it is generating mp3 having mime type audio/x-mpeg. I need mp3 file having mime type audio/mpeg to play in jw palyer. While when i record audio on the same apple device using browser this file is playing normally after converting from ffmpeg. – john Feb 24 '17 at 11:36
  • Yes, that is obvious, but either way you are executing the `ffmpeg` binary and it will output useful info to stderr. You should provide this info. – llogan Feb 24 '17 at 18:27
  • where i can find stderr ? – john Feb 24 '17 at 18:56
  • I need to convert mime type . I can't change any coding of jw player integration.Thanks – john Feb 24 '17 at 19:10

1 Answers1

0

You need to keep the mp3 with supported mime type.

Jwplayer does not support audio/x-mpeg format. Check here

Update:

1) audio format for iOS and Android

2) What are the audio-format encoders that Android and iOS have in common?

Hope this helps

Community
  • 1
  • 1
Hitesh
  • 4,098
  • 11
  • 44
  • 82
  • Is there any player that can be integrated in all type of devices on all platform and can run their generated audio/video files because i have app,website and i need to run files on different platforms , browsers etc. – john Feb 24 '17 at 11:38
  • added two links please check them if it is helpful – Hitesh Mar 03 '17 at 06:44