function popupChat() {
        win=window.open("demo4.html", "JPilotChat",
                   "resizable=no,height=600,width=800");
}     


function send()
{
   if (document.UserInfo.NICKNAME.value == null ||
                                        document.UserInfo.NICKNAME.value == "")
   {
        window.alert("You must enter your nick name.")
        return false
   }

 var USERNICK = document.UserInfo.NICKNAME.value

 win=window.open("","IRC","resizable=no,height=520,width=500")
 win.document.write('<html><head><title>JPilot jIRC Chat</title></head>')
 win.document.write('<body bgcolor="#C0C0C0">')


 win.document.write('<applet code="EIRC" archive="EIRC.jar,EIRC-gfx.jar" width="100%" height="550" align=center codebase="http://werde-legende.de/~webchat/standard/">')
                 win.document.write('<param name="server" value="irc.nonsense.irc-mania.de" />')
                 win.document.write('<param name="port" value="6666" /-->')
                 win.document.write('<!--param name="mainbg" value="#424242" /-->')
                 win.document.write('<param name="mainbg" value="#C0C0C0" />')
                 win.document.write('<param name="mainfg" value="#000000" />')
                 win.document.write('<param name="textbg" value="#FFFFFF" />')
                 win.document.write('<param name="textfg" value="#000000" />')
                 win.document.write('<param name="selbg" value="#00007F" />')
                 win.document.write('<param name="selfg" value="#FFFFFF" />')
                 win.document.write('<param name="channel" value="#IRC-Mania" />')
                 win.document.write('<param name="titleExtra" value="Chat" />')
                 win.document.write('<param name="username" value="SGsChat" />')
                 win.document.write('<param name="realname" value="WebChat, http://www.IRC-Mania.de" />')
                 win.document.write('<param name="nickname" value="'+USERNICK+'" />')
                 win.document.write('<!--param name="password" value="" /-->')
                 win.document.write('<!--param name="servPassword" value="" /-->')
                 win.document.write('<!--param name="servEmail" value="" /-->')
                 win.document.write('<param name="login" value="1" />')
                 win.document.write('<!--param name="spawn_frame" value="1" /-->')
                 win.document.write('<!--param name="frame_width" value="600" /-->')
                 win.document.write('<!--param name="frame_height" value="400" /-->')
                 win.document.write('<param name="language" value="de" /-->')
                 win.document.write('<param name="country" value="DE" /-->')

	win.document.close()
	return true
}
