﻿
function LoadJS( id, fileUrl ,charset) 
{ 
    if(charset==null) charset="utf-8";
    var scriptTag = document.getElementById(id); 
    var oHead = document.getElementsByTagName('HEAD').item(0); 
    var oScript= document.createElement("script"); 

    if (scriptTag) oHead.removeChild(scriptTag); 

    oScript.id = id; 
    oScript.type = "text/javascript"; 
    oScript.charset = charset;
    oScript.src=fileUrl ; 
    
    oHead.appendChild(oScript); 

} 
