Difference between revisions of "Widget:WikiDiagram"

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