Skip to content
Permalink
Browse files

Second part of changes. Doing this slowly to keep integrity between t…

…his branch and HEAD.
  • Loading branch information...
defacer
defacer committed Aug 25, 2004
1 parent 0b0d224 commit 6e82cd4cd3b5ff771da34ef3cc3c45935bc66eae
Showing with 21 additions and 28 deletions.
  1. +21 −28 mod/chat/gui_sockets/chatinput.php
@@ -27,8 +27,9 @@

<?php include("$CFG->javascript"); ?>

<script language="Javascript">
<script type="text/javascript">
<!--
scroll_active = true;
function empty_field_and_submit() {
cf = document.getElementById('chatform');
@@ -39,51 +40,43 @@ function empty_field_and_submit() {
document.f.chat_message.focus();
return false;
}
function prepareusers() {
var frm = window.parent.frames;
for(i = 0; i < frm.length; ++i) {
if(frm(i).name == "users") {
window.userFrame = frm(i);
window.setTimeout("reloadusers();", <?php echo $CFG->chat_refresh_userlist; ?> * 1000);
}
}
}
function reloadusers() {
if(window.userFrame) {
window.userFrame.location.reload();
window.setTimeout("reloadusers();", <?php echo $CFG->chat_refresh_userlist; ?> * 1000);
}
}
// -->
</script>
</head>

<body bgcolor="<?php echo $THEME->body ?>" onload="document.f.chat_message.focus();document.f.chat_message.select();">
<body bgcolor="<?php echo $THEME->body ?>" onload="document.f.chat_message.focus();document.f.chat_message.select(); prepareusers();">

<!--
<form action="<?php echo "http://$CFG->chat_serverhost:$CFG->chat_serverport"; ?>" method="GET" target="empty" name="f" onsubmit="return empty_field_and_submit()">
-->
<form action="../insert.php" method="GET" target="empty" name="f" onsubmit="return empty_field_and_submit()">

&gt;&gt;<input type="text" name="chat_message" size="60" value="<?php echo $chat_pretext; ?>">
<form action="../insert.php" method="get" target="empty" name="f" onsubmit="return empty_field_and_submit()">
&gt;&gt; <input type="text" name="chat_message" size="60" value="<?php echo $chat_pretext; ?>">
<?php helpbutton("chatting", get_string("helpchatting", "chat"), "chat", true, false); ?>
</form>



<form action="<?php echo "http://$CFG->chat_serverhost:$CFG->chat_serverport/"; ?>" method="GET" target="empty" id="chatform">
<!--
<form action="../insert.php" method="GET" target="empty" id="chatform" onsubmit="return empty_field_and_submit()">
-->
<form action="<?php echo "http://$CFG->chat_serverhost:$CFG->chat_serverport/"; ?>" method="get" target="empty" id="chatform">
<input type="hidden" name="win" value="message" />
<input type="hidden" name="chat_version" value="sockets" />
<input type="hidden" name="chat_message" value="" />
<input type="hidden" name="chat_msgidnr" value="0" />
<input type="hidden" name="chat_sid" value="<?php echo $chat_sid ?>" />
<input type="hidden" name="groupid" value="<?php echo $groupid ?>" />
</form>

<script type="text/javascript">
<!--
var frm = window.parent.frames;
for(i = 0; i < frm.length; ++i) {
if(frm(i).name == "users") {
window.userFrame = frm(i);
window.setTimeout("reloadusers();", 4000);
}
}
function reloadusers() {
window.userFrame.location.reload();
window.setTimeout("reloadusers();", 4000);
}
-->
</script>

</body>

</html>

0 comments on commit 6e82cd4

Please sign in to comment.
You can’t perform that action at this time.