I tried Amy's "Skyrocket Your Lander CTR/CR with these Code Snippets" and it works great for desktop but not with mobile. Does anyone know a code which would work with mobile too?
I simply put the this code <audio autoplay> <source src="audio/beep1.mp3"/></audio> at the body part. And it works well....
Does not work on iOS.... Works on Android, etc
Hmm I have it in body part too and it works great with desktop but not with my nexus 5 android phone. Could the amazon CDN be reason? And I want to emphasize that the desktop works fine.
Am I only one with this problem?
I´m having the same problem. My code is as follows:
<audio autoplay>
<source src="alert.ogg" type="audio/ogg">
<source src="alert.mp3" type="audio/mpeg">
</audio>
It works in desktop but not in android phones.
<script>
var audio = new Audio("url1");
function playAudio() {
audio.play();
}
var audio2 = new Audio("url2");
function playAudio2() {
audio2.play();
}
</script>
Then call the play-function where-ever needed.
This works for me as far as I know. If you want to play it on load just write onload="playAudio(); alert('....')"
Still doesn´t work. The alert shows up, but the sound does not play:
Here´s how I do it:
<script>
var audio = new Audio("alert.mp3");
function playAudio() {
audio.play();
alert("Body loaded");
}
</script>
</head>
<body onload="playAudio()">
Mobile phones do not support autoplay.
@pablo
Can't really tell you exactly what's wrong, but try for example set onclick="playAudio()" for something, then tap it and see if it plays, if not find out why, and so on. Maybe try just audio and no alert, or timeout on alert and so on. Try all you can think of and maybe something will stick. Some other stuff you can try: other audio file, base64 the audio and put in the the src.
Good luck!
Thanks @ysekse! If I have new findings I´ll post them.
Regards,
Pablo.
Found an alternative:
Howler.js: http://goldfirestudios.com/blog/104/...script-Library
Works perfect in Android.
Regards,
Pablo.
Have you noticed an increase in CTR with audio? Neither audio nor vibration did much for me. If anything it actually reduced CTR. Maybe I'm using the wrong sound. The only attention grabbing feature that have worked for me so far is the good ol' intro pop.