Hallo,
ich habe ein Problem, undzwar habe ich mir ein JavaScript gebastelt, welches die Eingabezeile nach dem Absenden (Entertaste) wieder löscht. Es funktioniert gut, allerdings nicht im Chrome Browser. Im Firefox und IE funktionierts. Wie bringe ich es auch in Chrome nun zum Laufen?
Es handelt sich hier um ein Template für die Texteingabe eines Chats.
hier meine Seite mit Script:
Ich bedanke mich herzlich
lG wik
ich habe ein Problem, undzwar habe ich mir ein JavaScript gebastelt, welches die Eingabezeile nach dem Absenden (Entertaste) wieder löscht. Es funktioniert gut, allerdings nicht im Chrome Browser. Im Firefox und IE funktionierts. Wie bringe ich es auch in Chrome nun zum Laufen?
Es handelt sich hier um ein Template für die Texteingabe eines Chats.
hier meine Seite mit Script:
Code:
<!DOCTYPE html PUBLIC "-//W3C//Dtd XHTML 1.0 transitional//EN" "http://www.w3.org/tr/xhtml1/Dtd/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Pragma" content="no-cache" />
<meta http-equiv="cache-control" content="no-cache" />
<meta http-equiv="Cache-Control" content="post-check=0, pre-check=0, false" />
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link href="http://[entfernt]/css/chat/chat.css" rel="stylesheet" type="text/css" />
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script language="JavaScript">
<!--
function sendForm(thisForm)
{
thisForm.submit();
if(thisForm.msg.value != '') {
thisForm.msg.value='';
return false;
}
thisForm.msg.focus();
}
//-->
</script>
</head>
<body onload="javascript:document.getElementById('msg').focus();">
<div>
<table width="100%">
<tr>
<td>
<div id="postsend">
<form name="f" method="post" action="http://%HOST%:%PORT%/MESSAGE" onSubmit="return sendForm(this);" autocomplete="off">
<div> <input type="text" id="msg" name="msg" class="inputtext1" autocomplete="off" style="width:80%; margin-bottom: 3px;"></div>
<input type="hidden" name="sessionid" value="%SESSIONID%"></form></div> </td></tr><tr><td>
<div><a href="http://%HOST%:%PORT%/MESSAGE?sessionid=%SESSIONID%&msg=/w" target="In">Im Raum</a> | <a href="http://%HOST%:%PORT%/MESSAGE?sessionid=%SESSIONID%&msg=/wc" target="In">Im Chat</a> | <a href="http://%HOST%:%PORT%/MESSAGE?sessionid=%SESSIONID%&msg=/away+kurz+weg" target="In">Abmelden</a> | <a href="http://%HOST%:%PORT%/MESSAGE?sessionid=%SESSIONID%&msg=/q" target="In">Chat verlassen</a> | <A HREF="http://%HOST%:%PORT%/CUSTOM?sessionid=%SESSIONID%&nh=%NH%&path=color.html" target="color" onclick="javascript:popup('http://%HOST%:%PORT%/CUSTOM?sessionid=%SESSIONID%&nh=%NH%&path=color.html','color','width=500,height=400, screenX=30, screenY=30,directories=no,toolbar=no,location=no,menubar=no,scrollbars=no,status=no,resizable=no,dependent=no')" >Farbe ändern</A></div>
</td>
</tr>
</table>
</div>
</body>
</html>
Ich bedanke mich herzlich
lG wik