Hi All,
How to Play Sound where record of mysql table is added?.
thank you.

Member Avatar
LastMitch

@gacoekchip.pokher

You need to create a db and table and rows.

Try this code:

$sound = "<embed src='ding.wav' height=0 width=0 hidden=true autostart=true loop=false volume=100 />";

if(mysql_insert_worked) //some condition that knows if it was successful
    {
         echo $sound;
    }

or

You also can used ajax in <embed>:

http://www.scriptol.com/ajax/anaa/demos.php

Try this code:

<embed src="ding.wav" id="sound2" width="0" heigh="0" autostart="false" enablejavascript="true"/>
Member Avatar
LastMitch

@gacoekchip.pokher

If you feel the question is solve, on your bottom left corner there's button called
"Mark Question Solved". Click on that button. Clicking that button means that your question has been answer so when other members needs to find this answer, they come at your thread to see the correct answer.