Difference between revisions of "Widget:WikiDiagram"

From Audacity Wiki
Jump to: navigation, search
(update.)
(bypass cloudflare)
 
(31 intermediate revisions by the same user not shown)
Line 3: Line 3:
  
 
</noinclude><includeonly>
 
</noinclude><includeonly>
<script data-cfasync="false" src="https://wit.audacityteam.org/js/wikidiagrams.js?time=1123"></script>
 
<script>
 
  
function receiveReply(event) {
+
<!--{if $page}-->
  var source = event.source;
+
<div id="content_here" class="atkContentDiv" data-page="<!--{$page|escape:'url'}-->" style="text-align:center;">
  console.log("Got Reply:" + event.data );
+
<!--{if $extra}-->
  var result = document.getElementById("result");
+
    <div style="display:none">
  resetHotspots();
+
<!--{else}-->
  loadNewDetails( event.data );
+
</div>
}
+
<!--{/if}-->
 +
<!--{/if}-->
  
function loaded(win){
+
<!--{if $fin}-->
  window.addEventListener("message", receiveReply, false);
+
</div></div>
 +
<!--{/if}-->
  
  //alert("page loaded");
+
<!--{if $init}-->
  A.page="<!--{$page|escape:'url'}-->"
+
<script data-cfasync="false" src="https://wit.audacityteam.org/js/wikidiagrams.js?time=1143"></script>
  createDomElements();
+
<script data-cfasync="false" src="https://wit.audacityteam.org/js/smiles.js?time=1143"></script>
  addImagesToDom();
 
  
  console.log(A.page);
+
<script>
  A.SpecName="Foo";
+
initContent();
 
+
</script>
  var trampoline = document.getElementById("trampoline").contentWindow;
+
<!--{/if}-->
  // Don't care who receiver is, if they give us back a spec
 
  trampoline.postMessage( A.page,"*");
 
}
 
  
</script>
 
<iframe id="trampoline" onload="loaded(this)" src="https://wit.audacityteam.org/trampoline.htm" style="display:none"></iframe><br>
 
<div id="content_here" style="text-align:center;">
 
</div>
 
<div id="atitle" style="text-align:center;">
 
    <em>No Hotspot Zones Loaded (Yet)</em>
 
</div>
 
<div id="tabular_contents"></div>
 
<div id="spec" style="margin-left:10px"></div>
 
 
<includeonly>
 
<includeonly>

Latest revision as of 22:18, 21 April 2020

This runs a script on loading complete