Skip to content

Commit

Permalink
Updated createSound() example, more links
Browse files Browse the repository at this point in the history
  • Loading branch information
scottschiller committed Apr 15, 2013
1 parent 56fea76 commit d157c24
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions index.html
Expand Up @@ -378,7 +378,7 @@ <h4>Basic SoundManager 2 set-up</h4>

<pre class="block"><code>&lt;script src="soundmanager2.js"&gt;&lt;/script&gt;
&lt;script&gt;
soundManager.setup({
<a href="doc/#soundmanager-createsound" title="soundManager.createSound() documentation" onclick="checkDomain()">soundManager.setup({
<span><span>// where to find flash audio SWFs, as needed</span></span>
url: '<span>/path/to/swf-files/</span>',
<span><span>// optional: prefer HTML5 over Flash for MP3/MP4
Expand Down Expand Up @@ -412,13 +412,12 @@ <h4>Basic playback control</h4>
<h4>Creating and playing a sound object</h4>

<pre class="block"><code><span><span>// create "mySound"...</span></span>
soundManager.createSound({
id: '<span>mySound</span>',
var mySound = <a href="doc/#soundmanager-createsound" title="soundManager.createSound() documentation" onclick="checkDomain()">soundManager.createSound</a>({
url: '<span>/path/to/an.mp3</span>'
});

<span><span>// ...and play it</span></span>
soundManager.play('<span>mySound</span>');
mySound.play();
</code></pre>

<p>Additional options and events can be specified when loading and playing sounds. For more examples of playback features, see <a href="demo/api/" class="cta">API Demos</a>.</p>
Expand Down

0 comments on commit d157c24

Please sign in to comment.