954,598 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Presto changeo! Change code to html5

I use a WYSIWYG tool to design my web pages, I want to change the part that handles sound to html5 so it will work better on another platform I want to use.

I have looked at the code my editor made, this looks like the bit that needs changing to me, I think its all there, all my web pages use the same technique/code to add sound, the only variant is that some use looping sound for some pages, so that also needs to be in mind.

<embed id = backmusic src="./media/explosion.wav" autostart="true" width="1" height="1" loop="false"></embed>
<noembed> <bgsound src="./media/explosion.wav" loop=false> </noembed>


Could someone show me what the code be if this was html5?
Thank you for help offered.

Pleasant Day
Junior Poster in Training
54 posts since Jun 2009
Reputation Points: 10
Solved Threads: 0
 
<audio src="source of file" autoplay>

    Non html5 here

</audio>


I believe that is the syntax

zizuno
Junior Poster in Training
62 posts since Jan 2011
Reputation Points: 10
Solved Threads: 8
 

Thank you for your answer
So do I put

<noembed> <bgsound src="./media/explosion.wav" loop=false> </noembed>

where you have it marked at
3. Non html5 here
That way I can say if its looped or not? Strange, I thought the code for looping or just playing once would also be written in html5 as well.

Pleasant Day
Junior Poster in Training
54 posts since Jun 2009
Reputation Points: 10
Solved Threads: 0
 

this works but the looping doesnt work

loop="loop">

Pleasant Day
Junior Poster in Training
54 posts since Jun 2009
Reputation Points: 10
Solved Threads: 0
 

Look at your syntax. You included an extra >.

zizuno
Junior Poster in Training
62 posts since Jan 2011
Reputation Points: 10
Solved Threads: 8
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: