Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'MDL-34068_22' of git://github.com/dmonllao/moodle into …

…MOODLE_22_STABLE
  • Loading branch information...
commit b216fc392f5ee78948fbd1d334863bc99a33c689 2 parents 698ecaf + 3e0f931
@nebgor nebgor authored
Showing with 11 additions and 1 deletion.
  1. +11 −1 mod/chat/chatd.php
View
12 mod/chat/chatd.php
@@ -538,8 +538,18 @@ function promote_final($sessionid, $customdata) {
// $this->trace('QUIRKS value for this connection is '.$customdata['quirks']);
+ $header = "HTTP/1.1 200 OK\n";
+ $header .= "Connection: close\n";
+ $header .= "Date: ".date('r')."\n";
+ $header .= "Server: Moodle\n";
+ $header .= "Content-Type: text/html; charset=utf-8\n";
+ $header .= "Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT\n";
+ $header .= "Cache-Control: no-cache, must-revalidate\n";
+ $header .= "Expires: Wed, 4 Oct 1978 09:32:45 GMT\n";
+ $header .= "\n";
+
$this->dismiss_half($sessionid, false);
- $this->write_data($this->conn_sets[$sessionid][CHAT_CONNECTION_CHANNEL], $CHAT_HTMLHEAD_JS);
+ $this->write_data($this->conn_sets[$sessionid][CHAT_CONNECTION_CHANNEL], $header . $CHAT_HTMLHEAD_JS);
$this->trace('Connection accepted: '.$this->conn_sets[$sessionid][CHAT_CONNECTION_CHANNEL].', SID: '.$sessionid.' UID: '.$chatuser->userid.' GID: '.$chatuser->groupid, E_USER_WARNING);
// Finally, broadcast the "entered the chat" message
Please sign in to comment.
Something went wrong with that request. Please try again.