using javascript to play audio on ipad

Discussion in 'iPad Development' started by john love, Nov 4, 2010.

  1. john love

    john love iPF Noob

    Joined:
    Nov 4, 2010
    Messages:
    1
    Thanks Received:
    0
    Trophy Points:
    0
    Ratings:
    +0 / 0
    Rather than repeat a long javascript for playing audio, here is the link: webpages.charter.net/jolove/Includes/play_song.js.

    This plays for any desktop browser (Mac or Windows), but not for my iPad.

    Here is the calling website: webpages.charter.net/jolove/Escort_Folder/Dedication_Poem_iOS.html

    This is really bugging me, so I would definitely appreciate any help on this, any help at all.

    John Love
     
  2. Draco18s

    Draco18s iPF Noob

    Joined:
    Dec 1, 2011
    Messages:
    1
    Thanks Received:
    0
    Trophy Points:
    0
    Ratings:
    +0 / 0
    Old thread is old, but I thought I'd at least drop an answer in here for future generations:

    Audio on the ipad CANNOT and WILL NOT autoplay via javascript or anything else on the iPad, as there is an iOS level restriction that requires the user to interact with the audio element before it will download, as to not incur datarate charges for 3G network usage without the user's consent.

    The audio element simply doesn't exist until the user clicks on it (and no, making your own button for the user to click on doesn't count).
     

Share This Page

Search tags for this page

html ipad play sound

,

html play sound on ipad

,
ipad html audio
,

ipad javascript play sound

,
javascript playing a sound on ipad