Feature #4105 some security filters

skala
Juan Carlos Raña 14 years ago
parent 59933448aa
commit d1a77adc62
  1. 2
      main/document/show_content.php
  2. 2
      main/document/showinframes.php
  3. 2
      main/document/showinframesmin.php

@ -88,7 +88,7 @@ $browser_display_title = 'Documents - '.Security::remove_XSS($_GET['cidReq']).'
$file_url_web = api_get_path(WEB_COURSE_PATH).$_course['path'].'/document'.$header_file.'?'.api_get_cidreq();
$pathinfo = pathinfo($header_file);
if ($pathinfo['extension']=='wav' && api_get_setting('enable_nanogong') == 'true'){
if ($pathinfo['extension']=='wav' && preg_match('/_chnano_.wav/i', $file_url_web) && api_get_setting('enable_nanogong') == 'true'){
echo '<div align="center">';
echo '<br/>';
echo '<applet id="applet" archive="../inc/lib/nanogong/nanogong.jar" code="gong.NanoGong" width="160" height="40" >';

@ -216,7 +216,7 @@ if ($show_web_odf) {
}
echo "</div>";
if ($pathinfo['extension']=='wav' && api_get_setting('enable_nanogong') == 'true'){
if ($pathinfo['extension']=='wav' && preg_match('/_chnano_.wav/i', $file_url_web) && api_get_setting('enable_nanogong') == 'true'){
echo '<div align="center">';
echo '<br/>';
echo '<applet id="applet" archive="../inc/lib/nanogong/nanogong.jar" code="gong.NanoGong" width="160" height="40">';

@ -146,7 +146,7 @@ echo '<div align="center">';
$file_url_web = api_get_path(WEB_COURSE_PATH).$_course['path'].'/document'.$header_file.'?'.api_get_cidreq();
$pathinfo = pathinfo($header_file);
if ($pathinfo['extension']=='wav' && api_get_setting('enable_nanogong') == 'true'){
if ($pathinfo['extension']=='wav' && preg_match('/_chnano_.wav/i', $file_url_web) && api_get_setting('enable_nanogong') == 'true'){
echo '<div align="center">';
echo '<br/>';
echo '<applet id="applet" archive="../inc/lib/nanogong/nanogong.jar" code="gong.NanoGong" width="160" height="40" >';

Loading…
Cancel
Save