function add_bb(id, open, close)
{
        comp = navigator.userAgent.toLowerCase();
        vers = parseInt(navigator.appVersion);
        msie = ((comp.indexOf("msie") != -1) && (comp.indexOf("opera") == -1));
        opera = ((comp.indexOf("opera") != -1));
        nets = ((comp.indexOf('mozilla')!=-1) && (comp.indexOf('spoofer')==-1) && (comp.indexOf('compatible') == -1) && (comp.indexOf('opera')==-1) && (comp.indexOf('webtv')==-1) && (comp.indexOf('hotjava')==-1));
        win  = ((comp.indexOf("win")!=-1) || (comp.indexOf("16bit") != -1));

        if (((vers >= 4) && msie && win) || opera) {
                selection = document.selection.createRange().text;

                if (!selection) {
                        document.getElementById(id).value += open + " " + close;
                        document.getElementById(id).focus();

                        return;
                }
                else {
                        document.selection.createRange().text = open + selection + close;
                        document.getElementById(id).focus();

                        return;
                }

                if (document.getElementById(id).createTextRange)
                        document.getElementById(id).caretPos = document.selection.createRange().duplicate();
        }
        else {
                document.getElementById(id).value += open + " " + close;
                document.getElementById(id).focus();
        }
}

function add_smile(id, ubb)
{
         var ubb = " " + ubb + " ";

         if (document.getElementById( id ).createTextRange)
         {
                           document.getElementById( id ).focus();
                           document.selection.createRange().duplicate().text = ubb;
         }
         else
         {
                           document.getElementById( id ).value += ubb;
         }
}

function navigatie(waar)
{
        eval("parent" + ".location = '" + waar.options[waar.selectedIndex].value + "'");
}