var redf={};
redf["loadExternalScript"]=function(url, callback, customAttr1, customAttr1Value)
{
// Adding the script tag to the head as suggested before
var head = document.head;
var script = document.createElement('script');
script.type = 'text/javascript';
script.src = url;
script.async = false;
script[customAttr1]=customAttr1Value;
// Then bind the event to the callback function.
// There are several events for cross browser compatibility.
script.onreadystatechange = callback;
script.onload = callback;
// Fire the loading
head.appendChild(script);
};
redf["loadScript"]=function(url, callback, customAttr1, customAttr1Value)
{
redf.loadExternalScript('https://snowbound.firstlightnetwork.co.uk/SNOW/'+'/'+url,callback, customAttr1, customAttr1Value);
};
redf["addHTMLToHead"]=function(HTML)
{
document.head.append(HTML);
};
redf["construct"]=function()
{
/* Add in standard css */
{
var link = document.createElement("link");
link["href"]='https://snowbound.firstlightnetwork.co.uk/SNOW/style/redf.css?v=1.0.19d';
link["rel"]='stylesheet';
link["type"]='text/css';
document.head.appendChild(link);
}
redf["getLocalDateFormat"]=function()
{
var now=new Date(2023,11,31);
var str=now.toLocaleDateString();
str=str.replace("31","dd");
str=str.replace("12","MM");
str=str.replace("2023","yyyy");
return str;
};
var callBackVenusIsloaded= function()
{
var addedHTML="";
addedHTML=addedHTML.replace(new RegExp("",'g'),"");
var processScriptHTML=function(strHTML,strTag)
{
var arrScripts=strHTML.split(new RegExp("<"+strTag+"(.*?)>"));
for(var i=0;i")
continue;
var s0 = document.createElement(strTag);
var arrKeyValuePairs=scriptParams.split(new RegExp(" "));
for(var j=0;j1)
{
var key=arrKeyValue.shift();
var value=arrKeyValue.join("=");//just in case nested equals
s0[key]=value.replace(new RegExp("'",'g'),"");
}
}
document.head.appendChild(s0);
}
}
processScriptHTML(addedHTML.replace(new RegExp("",'g'),""),"script");
processScriptHTML(addedHTML.replace(new RegExp("