- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
Hi intel, I new to XDK, but anyway I succeded to convert an html website into an .apk.
My issue: I have many wav files embeded in my site trough the default HTML5 audio player which I enabled with the help of the "player" plugin. When I am testing the player in the emulator it works fine, plays the file without problems. After I build the app, the player is there but it is inactive on the device as if there would be no .wav file loaded. Any help would be apreciated!
I am usig the following code to call the player:
<audio class="widget uib_w_2 d-margins" data-uib="media/audio" data-ver="0" controls="controls">
<source src="sounds/soundfile.wav" type="audio/wav"> </audio>
- Теги:
- HTML5
- Intel® XDK
Ссылка скопирована
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
Take a look at this demo app, it shows two ways to play the audio files, probably how you reference the files is the problem. Note that the <audio> tag does not work on many older devices. Best bet is to use Crosswalk for Android if you want that to work reliably, or use the Cordova Media function or one of the many third-party plugins out there.
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
Also, the wav format is not well supported by browsers that even do support <audio>. You'd be better off using mp3 and ogg.
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
Try using the Debug tab to figure out where those messages are coming from. It runs your app in Crosswalk.
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
I don't know if this is connected or not, but it might also be worth adding preload="none" to all of the <audio> declarations to prevent the app from trying to start loading all your sound files in one go. In the web world Chrome has a problem with this, as it has a limit of 6 or so, so it's possible that this is also a problem here?
Just a thought.

- Подписка на RSS-канал
- Отметить тему как новую
- Отметить тему как прочитанную
- Выполнить отслеживание данной Тема для текущего пользователя
- Закладка
- Подписаться
- Страница в формате печати