function Get_Obj(id) {
var o = new Object();
o.o = (document.getElementById) ? document.getElementById(id) :
document.layers ? document.layers[id] :
document.all ? document.all[id] : null;
o.s = document.layers ? o.o : o.o.style;
return o;
}

function showLayer(id) {Get_Obj(id).s.visibility = 'visible';}

function showLayers() {for (var i=0; i<arguments.length; i++) showLayer(arguments[i]);}

function hideLayer(id) {	Get_Obj(id).s.visibility = 'hidden';}

function hideLayers() {	for (var i=0; i<arguments.length; i++) hideLayer(arguments[i]);}


function storeCaret () { 
if (formulier.ainhoud.createTextRange) 
formulier.ainhoud.caretPos = 
document.selection.createRange().duplicate(); 
} 

function invoegen(thecode) { 
if (navigator.userAgent.indexOf("Opera") == -1) 
{ 
if (formulier.ainhoud.createTextRange 
&& formulier.ainhoud.caretPos) { 
var caretPos = formulier.ainhoud.caretPos; 
caretPos.text = 
caretPos.text.charAt(caretPos.text.length - 1) == ' ' ? 
thecode + ' ' : thecode; 
document.formulier.ainhoud.focus(); 
} 
else 
formulier.ainhoud.value = thecode; 
storeCaret(); 
document.formulier.ainhoud.focus(); 

} 
} 
