104 lines
2.9 KiB
HTML
104 lines
2.9 KiB
HTML
<!DOCTYPE html>
|
|
<html lang='en'>
|
|
<head>
|
|
<meta charset='UTF-8'/>
|
|
<meta name='viewport' content='width=device-width, initial-scale=1.0'/>
|
|
<meta http-equiv='Expires' content='0'/>
|
|
<link rel='stylesheet' type='text/css' href='/css/all.css'/>
|
|
<script type='text/javascript' src='/client.js?ver=2.43'></script>
|
|
<title>kAmMa's Forum</title>
|
|
</head>
|
|
<body>
|
|
<div class='page' style='width:100%; text-align:left'>
|
|
<div style='padding:0 25px 0 25px'>
|
|
<br/>
|
|
{{COMMON_HEADER}}
|
|
<br/>
|
|
|
|
<table class='tborder' cellpadding='6' cellspacing='1' border='0' width='100%' align='center'>
|
|
<thead>
|
|
<tr align='center'>
|
|
<td class='thead' width='100%' align='left'>Chat</td>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr align='center'>
|
|
<td class='alt1Active' align='left'>
|
|
<form action='' name='chatForm' onsubmit='return sendMessage();'>
|
|
<div class='smallfont'>Message:</div>
|
|
<div id='vB_Editor_QR' class='vBulletin_editor'>
|
|
<div class='controlbar' style='padding-right:8px'>
|
|
<fieldset style='border:0; padding:0; margin:0'>
|
|
<input type='text' onkeypress='return makeRecordsReaded(event)' name='message' style='width:100%'/>
|
|
<input type='submit' class='button' value='Send Message'/>
|
|
</fieldset>
|
|
</div>
|
|
</div>
|
|
<br/>
|
|
<hr/>
|
|
<br/>
|
|
<div id='main_chat'><center><h3>Loading messages...</h3></center></div>
|
|
</form>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<br/>
|
|
|
|
<div class='smallfont'><label><input type='checkbox' id='soundon' checked='checked'/> Sound notification</label></div>
|
|
<br/>
|
|
|
|
{{COMMON_FOOTER}}
|
|
</div>
|
|
</div>
|
|
|
|
<script type='text/javascript'>
|
|
function sendMessage() {
|
|
var maxChatId = 0;
|
|
var divs = document.getElementsByTagName('div');
|
|
for (var i = 0; i <= (divs.length - 1); i++) {
|
|
var att = divs[i].attributes.getNamedItem('id');
|
|
if (att && att.value.indexOf('chatId_') > -1) {
|
|
var currChatId = parseInt(att.value.substring(7));
|
|
if (currChatId > maxChatId) {
|
|
maxChatId = currChatId;
|
|
}
|
|
}
|
|
}
|
|
|
|
AX_sendChatMessage(encodeURIComponent(document.chatForm.message.value), maxChatId);
|
|
document.chatForm.message.value = '';
|
|
document.chatForm.message.focus();
|
|
return false;
|
|
}
|
|
|
|
function makeRecordsReaded(e) {
|
|
var keynum;
|
|
if (window.event) {
|
|
keynum = e.keyCode;
|
|
} else if (e.which) {
|
|
keynum = e.which;
|
|
}
|
|
if (keynum === 13) {
|
|
var title = document.title;
|
|
title = title.replace('(CHAT+)', '');
|
|
document.title = title.trim();
|
|
}
|
|
return true;
|
|
}
|
|
|
|
function asynchUpdateChat() {
|
|
AX_asynchUpdateChat();
|
|
setTimeout('asynchUpdateChat();', 5000);
|
|
}
|
|
|
|
function firstUpdateChat() {
|
|
AX_firstUpdateChat();
|
|
setTimeout('asynchUpdateChat();', 5000);
|
|
}
|
|
|
|
firstUpdateChat();
|
|
</script>
|
|
</body>
|
|
</html>
|