function createCaret(textEl) {
	if (textEl.createTextRange)
		textEl.caretPos = document.selection.createRange().duplicate();
}

function insertCode(openTag, tagData, closeTag) {
	if (document.all.sprofile.createTextRange && document.all.sprofile.caretPos) {
		var caretPos = document.all.sprofile.caretPos;
		caretPos.text = openTag+caretPos.text+closeTag;
	} else {
		document.all.sprofile.value += openTag+tagData+closeTag;
		document.all.sprofile.focus();
	}
}

function putButton(toolTip, textdis, openTag, tagData, closeTag) {
	document.write("<input class=fb type=button value=\"" +textdis+ "\"  onClick=\"javascript:insertCode(\'"+openTag+"\', \'"+tagData+"\', \'"+closeTag+"\');\" onmouseover=\"document.all.tooltip.innerHTML='"+toolTip+"';\" onmouseover=\"document.all.tooltip.innerHTML='';\" onfocus=\"document.all.sprofile.focus();\">");
}

function vietbar(){
    if ((navigator.appName.indexOf("Microsoft") != -1) && (parseInt(navigator.appVersion) >= 4)) {
    document.write('<TABLE cellpadding="0" cellspacing="0" border="0" width="250"><TR><TD align="left" width="75" bgcolor="#EEEEEE" colspan="3">');
    document.write('<TABLE cellpadding="0" cellspacing="0" border="0" width="250">');
    document.write('<TR>');
    document.write('<TD bgcolor=blue width="0"><Img src="layout/spacer.gif" name="u1" height="12" width="0"></TD>');
    document.write('<TD bgcolor=#F0F0F0 width="250"><Img src="layout/spacer.gif" name="u2" height="12" width="250"></TD>');
    document.write('</TR>');
    document.write('</TABLE>');
    document.write('</TD></TR></table>');
   }
    else document.write(' ');
}


function f1(a,num){
    x = num - a.value.length;
    if (x < 0) { a.value = a.value.substring(0,num); x = 0; }
    document.u1.width=250*(num-x)/num;
    document.u1.alt=num-x+" karakters reeds gebruikt";
    document.u2.width=250*x/num;
    document.u2.alt=x+" karakters nog te gebruiken";
}



function changeto(e,highlightcolor){
   return true;
}

function changeback(e,oldcolor2){
   return true;
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}