1window.addEventListener("message", function(e) { 2 if(!e.data) { 3 return; 4 } else if (e.data.function && e.data.trigger && e.data.value) { 5 switch(e.data.function) { 6 case "getScrollHeight": 7 document.getElementById(e.data.trigger).height = e.data.value; 8 break; 9 default: 10 console.error("RIS Message API wurde falsch verwendet! [ERROR: Funktion nicht definiert]"); 11 break; 12 } 13 } 14}); 15 16var iFramesToResize = document.querySelectorAll("iframe.jsResizeIframe"); 17 18for (var idx = 0; idx < iFramesToResize.length; idx++) { 19 var curIframe = iFramesToResize[idx]; 20 21 curIframe.height = 256; 22 curIframe.style.background = "transparent url('https://cdnfile.riskommunal.net/cdnstatic/system/Javascriptz/ris/iFrameLoading.svg') no-repeat center center"; 23 curIframe.style.backgroundSize = "3em"; 24 curIframe.addEventListener("load", function(e) { 25 curIframe.style.background = ""; 26 curIframe.style.backgroundSize = ""; 27 setTimeout(function(curIframe) { 28 var request = { 29 "function": "getScrollHeight", 30 "trigger": curIframe.id 31 } 32 33 curIframe.contentWindow.postMessage(request,'*'); 34 }, 256, curIframe); 35 }); 36}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.