Okay
  Public Ticket #3559810
Playing an MP3 file from a PDF Pushbutton
Closed

Comments

  • Don Burns started the conversation

    I'm developing a WordPress website which has a PDF.js pluggin that displays a PDF file. The PDF file has mp3 files attached to it. It also has pushbutton objects which run a java script that opens the MP3 player and plays one of the attached MP3 files.

    Here's an example of one of the the Java scripts: 

    this.exportDataObject({cName: "Lick 01.mp3", nLaunch: 2 });

    When the PDF file is run on a computer, it opens the default mp3 player in a floating window and begins playing a mp3 file.

    Is there a similar Java script that would would open the Sonaar player and play a specified mp3 file? 

     I'm new to website development, and would appreciate any help you can offer.

    Thanks,

    Don Burns 

  •  1,114
    Max replied

    Hi Don,

    The only way to do this might be by using an URL instead of a MP3 file. See documentation: https://sonaar.io/docs/using-javascript-api/#1-toc-title

    Thanks,


    Max from the Sonaar.io Crew