Skip to content

Commit 589e001

Browse files
committed
Fixes URL see BT#9266
1 parent 040dcd6 commit 589e001

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

main/chat/chat.php

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
$open_chat_window = api_get_course_setting('allow_open_chat_window');
4040
}
4141

42-
$cidreq = Security::remove_XSS($_GET['cidReq']);
42+
$courseCode = Security::remove_XSS($_GET['cidReq']);
4343

4444
?>
4545
<!DOCTYPE html>
@@ -76,12 +76,13 @@
7676
}
7777

7878
$url = api_get_path(WEB_CODE_PATH).'chat/';
79+
$params = "cidReq=".$courseCode.'&id_session='.api_get_session_id();
7980

8081
echo '<div class="page-chat">';
81-
echo '<iframe src="'.$url.'chat_whoisonline.php?cidReq='.$cidreq.'" name="chat_whoisonline" scrolling="no" style="height:550px; width:35%; border: 0px none; float:left"></iframe>';
82-
echo '<iframe src="'.$url.'chat_chat.php?origin='.$origin.'&target='.$target.'&amp;cidReq='.$cidreq.'" name="chat_chat" id="chat_chat" scrolling="auto" height="380" style="width:65%; border: 0px none; float:right"></iframe>';
83-
echo '<iframe src="'.$url.'chat_message.php?cidReq='.$cidreq.'" name="chat_message" scrolling="no" height="182px" style="width:65%; border: 0px none; float:right"></iframe>';
84-
echo '<iframe src="'.$url.'chat_hidden.php?cidReq='.$cidreq.'" name="chat_hidden" height="0" style="border: 0px none"></iframe>';
82+
echo '<iframe src="'.$url.'chat_whoisonline.php?'.$params.'" name="chat_whoisonline" scrolling="no" style="height:550px; width:35%; border: 0px none; float:left"></iframe>';
83+
echo '<iframe src="'.$url.'chat_chat.php?origin='.$origin.'&target='.$target.'&'.$params.'" name="chat_chat" id="chat_chat" scrolling="auto" height="380" style="width:65%; border: 0px none; float:right"></iframe>';
84+
echo '<iframe src="'.$url.'chat_message.php?'.$params.'" name="chat_message" scrolling="no" height="182px" style="width:65%; border: 0px none; float:right"></iframe>';
85+
echo '<iframe src="'.$url.'chat_hidden.php?'.$params.'" name="chat_hidden" height="0" style="border: 0px none"></iframe>';
8586
echo '</div>';
8687

8788
if (empty($open_chat_window)) {

0 commit comments

Comments
 (0)