function addText(instext) {
    var mess = document.guestbook.message;
        //IE support
        if (document.selection) {
            mess.focus();
            sel = document.selection.createRange();
            sel.text = instext;
            document.guestbook.focus();
        }
        //MOZILLA/NETSCAPE support
        else if (mess.selectionStart || mess.selectionStart == "0") {
            var startPos = mess.selectionStart;
            var endPos = mess.selectionEnd;
            var chaine = mess.value;

            mess.value = chaine.substring(0, startPos) + instext + chaine.substring(endPos, chaine.length);

            mess.selectionStart = startPos + instext.length;
            mess.selectionEnd = endPos + instext.length;
            mess.focus();
        } else {
            mess.value += instext;
            mess.focus();
        }
    }
function afficher_visuel() 
{ 
ch=document.guestbook.message.value 
source=new Array("<br>","<strong>","</strong>","<em>","</em>","<u>","</u>","<div align=left>","</div>","<div align=center>","</div>","<div align=right>","</div>","<a href='http://www.aeropilot.fr/?PHPSESSID=3e09513442b7f72e1cb0aad47a3683fd'>","</a>") 
cible= new Array("<br>","<strong>","</strong>","<em>","</em>","<u>","</u>","<div align=left>","</div>","<div align=center>","</div>","<div align=right>","</div>","<a href='http://www.aeropilot.fr/?PHPSESSID=3e09513442b7f72e1cb0aad47a3683fd'>","</a>") 

i=0 
while(source[i]) 
{ 
ch2=ch.split(source[i]) 
ch=ch2.join(cible[i]) 
i++ 
} 
ch=ch.replace(/\n/g,"<br>") 
obj=document.getElementById("visuel") 
obj.innerHTML="<strong>Preview :</strong><hr width=100% color=black><blockquote style=margin:10px>"+ch+"</blockquote>" 
} 
function auto_close(delai)
{ setTimeout("self.close();",delai); }