Difference between revisions of "Template:SNDS PREVIEW"

From Olekdia Wiki
Line 1: Line 1:
 
{{#tag:html
 
{{#tag:html
|<button onclick="var numChild=2;var children=this.children;this.firstChild.paused?this.firstChild.play():this.firstChild.pause();children[1].src='a/olekdia/wiki_resources/'+(this.firstChild.paused?'ic_play.svg':'ic_pause.svg');this.firstChild.onended=function(){if(children.length>numChild){this.src='a/prana_breath/soundfiles/'+children[numChild].innerHTML;numChild++;this.load();this.play();}else children[1].src='a/olekdia/wiki_resources/ic_play.svg'; }"><audio><source src="a/prana_breath/soundfiles/{{{1}}}" type="audio/ogg"/></audio><img src="a/olekdia/wiki_resources/ic_play.svg" width="30"/>{{#if: {{{2|}}}|<span class="hidden-block">{{{2}}}</span>}}{{#if: {{{3|}}}|<span class="hidden-block">{{{3}}}</span>}}{{#if: {{{4|}}}|<span class="hidden-block">{{{4}}}</span>}}{{#if: {{{5|}}}|<span>{{{5}}}</span>}}</button>
+
|<button onclick="var numChild=2;var children=this.children;this.firstChild.paused?this.firstChild.play():this.firstChild.pause();children[1].src='a/olekdia/wiki_resources/'+(this.firstChild.paused?'ic_play.svg':'ic_pause.svg');this.firstChild.onended=function(){if(children.length>numChild){this.src='a/prana_breath/soundfiles/'+children[numChild].innerHTML;numChild++;this.load();this.play();}else children[1].src='a/olekdia/wiki_resources/ic_play.svg';}"><audio><source src="a/prana_breath/soundfiles/{{{1}}}" type="audio/ogg"/></audio><img src="a/olekdia/wiki_resources/ic_play.svg" width="30"/>{{#if: {{{2|}}}|<span class="hidden-sp">{{{2}}}</span>}}{{#if: {{{3|}}}|<span class="hidden-sp">{{{3}}}</span>}}{{#if: {{{4|}}}|<span class="hidden-sp">{{{4}}}</span>}}{{#if: {{{5|}}}|<span class="hidden-sp">{{{5}}}</span>}}</button>
 
|
 
|
 
|}}
 
|}}
 +
<noinclude>
 +
<pre>
 +
<button onclick="var numChild=2;var children=this.children;this.firstChild.paused?this.firstChild.play():this.firstChild.pause();children[1].src='a/olekdia/wiki_resources/'+(this.firstChild.paused?'ic_play.svg':'ic_pause.svg');this.firstChild.onended=function(){if(children.length>numChild){this.src='a/prana_breath/soundfiles/'+children[numChild].innerHTML;numChild++;this.load();this.play();}else{children[1].src='a/olekdia/wiki_resources/ic_play.svg';}}"><audio>
 +
  <source src="a/prana_breath/soundfiles/sh_voice_bg_female_darina_0.ogg" type="audio/ogg">
 +
  Your browser does not support the audio element.
 +
  </audio><img src="a/olekdia/wiki_resources/ic_play.svg" width="30"/>
 +
  <span style="display: none;">sh_voice_bg_female_darina_2.ogg</span>
 +
  <span style="display: none;">sh_voice_bg_female_darina_1.ogg</span>
 +
  <span style="display: none;">sh_voice_bg_female_darina_4.ogg</span>
 +
</button>
 +
</pre>
 +
</noinclude>

Revision as of 15:50, 24 January 2019

<button onclick="var numChild=2;var children=this.children;this.firstChild.paused?this.firstChild.play():this.firstChild.pause();children[1].src='a/olekdia/wiki_resources/'+(this.firstChild.paused?'ic_play.svg':'ic_pause.svg');this.firstChild.onended=function(){if(children.length>numChild){this.src='a/prana_breath/soundfiles/'+children[numChild].innerHTML;numChild++;this.load();this.play();}else{children[1].src='a/olekdia/wiki_resources/ic_play.svg';}}"><audio>
  <source src="a/prana_breath/soundfiles/sh_voice_bg_female_darina_0.ogg" type="audio/ogg">
   Your browser does not support the audio element.
   </audio><img src="a/olekdia/wiki_resources/ic_play.svg" width="30"/>
   <span style="display: none;">sh_voice_bg_female_darina_2.ogg</span>
   <span style="display: none;">sh_voice_bg_female_darina_1.ogg</span>
   <span style="display: none;">sh_voice_bg_female_darina_4.ogg</span>
</button>