skala
Julio Montoya 14 years ago
commit 227442addf
  1. 4
      documentation/changelog.html
  2. 2
      documentation/credits.html
  3. 4
      documentation/dependencies.html
  4. 2
      documentation/index.html
  5. 2
      documentation/installation_guide.html
  6. 2
      documentation/installation_guide_es_ES.html
  7. 4
      documentation/license.html
  8. 2
      documentation/optimization.html
  9. 2
      documentation/readme.html
  10. 33
      main/admin/settings.lib.php
  11. 2
      main/document/create_drawing.php
  12. 4
      main/document/document.inc.php
  13. 2
      main/document/document.php
  14. 2
      main/document/edit_drawing.php
  15. BIN
      main/img/ogg_big.png
  16. 17
      main/inc/lib/add_course.lib.inc.php
  17. 6
      main/inc/lib/document.lib.php
  18. 23
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/inc/class.manager.php
  19. 32
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/inc/config.base.php
  20. 21
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/css/fckeditor.css
  21. 21
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/css/stand_alone.css
  22. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/big_icon/fileODG.png
  23. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/big_icon/fileODP.png
  24. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/big_icon/fileODS.png
  25. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/big_icon/fileODT.png
  26. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/big_icon/fileOGG.png
  27. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/big_icon/fileSVG.png
  28. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/small_icon/fileODG.png
  29. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/small_icon/fileODP.png
  30. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/small_icon/fileODS.png
  31. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/small_icon/fileODT.png
  32. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/small_icon/fileOGG.png
  33. BIN
      main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/theme/default/images/small_icon/fileSVG.png
  34. 7
      main/inc/lib/fileDisplay.lib.php
  35. 8
      main/inc/lib/fileUpload.lib.php
  36. 7
      main/inc/lib/javascript/thickbox.js
  37. 32
      main/inc/lib/main_api.lib.php
  38. 15
      main/newscorm/resourcelinker.inc.php
  39. 2
      main/work/work.lib.php
  40. 6
      plugin/bbb/course_index.php
  41. 14
      plugin/bbb/course_install.php
  42. 3
      plugin/bbb/index.php
  43. 41
      plugin/bbb/install.php
  44. 20
      plugin/bbb/plugin.php
  45. 1
      plugin/bbb/readme.txt
  46. 31
      plugin/bbb/uninstall.php
  47. 6
      plugin/date/plugin.php
  48. 1
      user_portal.php

@ -3,7 +3,7 @@
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Chamilo Changelog</title><link rel="stylesheet" href="default.css" type="text/css" media="screen,projection" />
<link rel="shortcut icon" href="./favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon" />
<style type="text/css">
<!--
@page { size: 21cm 29.7cm; margin: 2cm }
@ -34,6 +34,7 @@
<li>The documents tool and the learn path tool can display vectorial images</li>
<li>An optional "Course (training) validation" feature has been implemented. When it is activated, teachers loose ability to create coursers. Teachers fill course requests instead. Then, after approval, the requested courses are created by the platform administrator. (Feature # 2099)</li>
<li>A new UI option "Fill with exemplary content" have been added to the forms about training/course creation. Now teachers and platform administrators are able to choose whether exemplary content should be put or not in the trainings/courses they are going to create. When a training/course is not created directly by a user, then the platform setting "Example material on training creation" is taken into account. (Feature # 539)</li>
<li>Added install/uninstall script possibilities for plugins (BT#1752)</li>
</ul>
<h3>Debugging</h3>
<ul>
@ -65,6 +66,7 @@
<li>Fixed bug deleting course teacher in admin edition #2109</li>
<li>Gradebook: Hiding print icon in Certificates BT#1650</li>
<li>Link Tool: IE icons replaced</li>
<li>Wiki: fix behaviour of plugin wikilink #2217</li>
</ul>
<h3>Security</h3>

@ -3,7 +3,7 @@
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Chamilo Credits</title><link rel="stylesheet" href="default.css" type="text/css" media="screen,projection" />
<link rel="shortcut icon" href="./favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon" />
<style type="text/css">
<!--
@page { size: 21cm 29.7cm; margin: 2cm }

@ -3,7 +3,7 @@
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Chamilo 1.8.7 Server Dependencies</title><link rel="stylesheet" href="default.css" type="text/css" media="screen,projection" />
<link rel="shortcut icon" href="./favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon" />
<style type="text/css">
<!--
@page { size: 21cm 29.7cm; margin: 2cm }
@ -67,4 +67,4 @@ has been strongly tested already and seems fine.</li>
<a href="http://jigsaw.w3.org/css-validator/">
<img src="http://jigsaw.w3.org/css-validator/images/vcss-blue" style="margin: 1em; float: right;" alt="Valid CSS" />
</a>
</body></html>
</body></html>

@ -3,7 +3,7 @@
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Chamilo 1.8.7.1</title><link rel="stylesheet" href="default.css" type="text/css" media="screen,projection" />
<link rel="shortcut icon" href="./favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon" />
<style type="text/css">
<!--
page { width: 21cm; height: 29.7cm; margin: 2cm }

@ -3,7 +3,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Chamilo 1.8.7.1 Installation Guide</title><link rel="stylesheet" href="default.css" type="text/css" media="screen,projection" />
<link rel="shortcut icon" href="./favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon" />
<style type="text/css">
<!--
page { width: 21cm; height: 29.7cm; margin: 2cm }

@ -4,7 +4,7 @@
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Guia de Instalación de Chamilo 1.8.7.1</title>
<link rel="stylesheet" href="default.css" type="text/css" media="screen,projection" />
<link rel="shortcut icon" href="./favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon" />
<style type="text/css">
<!--
page { width: 21cm; height: 29.7cm; margin: 2cm }

@ -4,7 +4,7 @@
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Chamilo License</title>
<link rel="stylesheet" href="default.css" type="text/css" media="screen,projection" />
<link rel="shortcut icon" href="./favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon" />
<style type="text/css">
<!--
@page { size: 21cm 29.7cm; margin: 2cm }
@ -723,4 +723,4 @@ Public License instead of this License. But first, please read
alt="Valid CSS" />
</a>
</body>
</html>
</html>

@ -3,7 +3,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Chamilo 1.8.7.1 Optimization Guide</title><link rel="stylesheet" href="default.css" type="text/css" media="screen,projection" />
<link rel="shortcut icon" href="./favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon" />
<style type="text/css">
<!--
page { width: 21cm; height: 29.7cm; margin: 2cm }

@ -2,7 +2,7 @@
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Chamilo Information</title><link rel="stylesheet" href="default.css" type="text/css" media="screen,projection" />
<link rel="shortcut icon" href="./favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon" />
<style type="text/css">
<!--
@page { size: 21cm 29.7cm; margin: 2cm }

@ -43,7 +43,6 @@ function handle_plugins() {
$user_id = api_get_user_id();
$category = $_GET['category'];
event_system(LOG_CONFIGURATION_SETTINGS_CHANGE, LOG_CONFIGURATION_SETTINGS_CATEGORY, $category, $time, $user_id);
Display :: display_confirmation_message(get_lang('SettingsStored'));
}
@ -91,6 +90,8 @@ function handle_plugins() {
echo get_lang('Header');
echo '</th><th>';
echo get_lang('Footer');
echo '</th><th>';
echo get_lang('CourseTool');
echo '</th>';
echo '</tr>';
@ -137,6 +138,7 @@ function handle_plugins() {
display_plugin_cell('mycourses_menu', $plugin_info, $testplugin, $usedplugins);
display_plugin_cell('header', $plugin_info, $testplugin, $usedplugins);
display_plugin_cell('footer', $plugin_info, $testplugin, $usedplugins);
display_plugin_cell('course_tool_plugin', $plugin_info, $testplugin, $usedplugins);
echo '</tr>';
}
}
@ -398,20 +400,45 @@ function store_plugins() {
$table_settings_current = Database :: get_main_table(TABLE_MAIN_SETTINGS_CURRENT);
global $_configuration;
// Get a list of all current 'Plugins' settings
$installed_plugins = api_get_settings('Plugins','list',$_configuration['access_url']);
$shortlist_installed = array();
foreach ($installed_plugins as $plugin) {
$shortlist_installed[] = $plugin['subkey'];
}
$shortlist_installed = array_flip(array_flip($shortlist_installed));
// Step 1 : We remove all the plugins.
//$sql = "DELETE FROM $table_settings_current WHERE category='Plugins'";
//Database::query($sql);
$r = api_delete_category_settings('Plugins', $_configuration['access_url']);
$shortlist_required = array();
// Step 2: Looping through all the post values we only store these which are really a valid plugin location.
foreach ($_POST as $form_name => $formvalue) {
$form_name_elements = explode('-', $form_name);
if (is_valid_plugin_location($form_name_elements[1])) {
$shortlist_required[] = $form_name_elements[0];
//$sql = "INSERT into $table_settings_current (variable,category,selected_value) VALUES ('".$form_name_elements['1']."','Plugins','".$form_name_elements['0']."')";
//Database::query($sql);
api_add_setting($form_name_elements['0'], $form_name_elements['1'], $form_name_elements['0'], null, 'Plugins', $form_name_elements['0'], null, null, null, $_configuration['access_url'], 1);
// check if there is an install procedure
$pluginpath = api_get_path(SYS_PLUGIN_PATH).$form_name_elements[0].'/install.php';
if (is_file($pluginpath) && is_readable($pluginpath)) {
//execute the install procedure
include $pluginpath;
}
}
}
foreach ($shortlist_installed as $plugin) {
// if one plugin was really deleted, execute the uninstall script
if (!in_array($plugin,$shortlist_required)) {
// check if there is an install procedure
$pluginpath = api_get_path(SYS_PLUGIN_PATH).$plugin.'/uninstall.php';
if (is_file($pluginpath) && is_readable($pluginpath)) {
//execute the install procedure
include $pluginpath;
}
}
}
}
/**
@ -419,7 +446,7 @@ function store_plugins() {
* @author Patrick Cool <patrick.cool@UGent.be>, Ghent University
*/
function is_valid_plugin_location($location) {
static $valid_locations = array('loginpage_main', 'loginpage_menu', 'campushomepage_main', 'campushomepage_menu', 'mycourses_main', 'mycourses_menu', 'header', 'footer');
static $valid_locations = array('loginpage_main', 'loginpage_menu', 'campushomepage_main', 'campushomepage_menu', 'mycourses_main', 'mycourses_menu', 'header', 'footer', 'course_tool_plugin');
return in_array($location, $valid_locations);
}

@ -132,7 +132,7 @@ echo '<div class="actions">';
echo '<a href="document.php?curdirpath='.Security::remove_XSS($_GET['dir']).'">'.Display::return_icon('back.png',get_lang('BackTo').' '.get_lang('DocumentsOverview')).get_lang('BackTo').' '.get_lang('DocumentsOverview').'</a>';
echo '</div>';
if (api_support_svg()){
if (api_browser_support('svg')){
//automatic loading the course language
$svgedit_code_translation_table = array('' => 'en', 'pt' => 'pt-Pt', 'sr' => 'sr_latn');

@ -125,7 +125,7 @@ function create_document_link($www, $title, $path, $filetype, $size, $visibility
$ext = strtolower($ext[sizeof($ext) - 1]);
// "htmlfiles" are shown in a frameset
if ($ext == 'htm' || $ext == 'html' || $ext == 'gif' || $ext == 'jpg' || $ext == 'jpeg' || $ext == 'png' || $ext == 'pdf' || $ext == 'swf' || $ext == 'mp3' || ($ext == 'svg' || $ext =='svgz' && api_support_svg())) {
if ($ext == 'htm' || $ext == 'html' || $ext == 'gif' || $ext == 'jpg' || $ext == 'jpeg' || $ext == 'png' || $ext == 'pdf' || $ext == 'swf' || $ext == 'mp3' || $ext == 'mp4' ||(($ext== 'ogg' || $ext== 'ogx' || $ext== 'oga' || $ext== 'ogv') && api_browser_support('ogg')) ||($ext == 'svg' && api_browser_support('svg'))) {
$url = 'showinframes.php?'.api_get_cidreq().'&amp;file='.$url_path.$req_gid;
} else {
// url-encode for problematic characters (we may not call them dangerous characters...)
@ -300,7 +300,7 @@ function build_edit_icons($curdirpath, $type, $path, $visibility, $id, $is_templ
if ($is_certificate_mode) {
$modify_icons = '<a href="edit_document.php?'.api_get_cidreq().'&curdirpath='.$curdirpath.'&amp;file='.urlencode($path).$req_gid.'&selectcat='.$gradebook_category.'"><img src="../img/edit.gif" border="0" title="'.get_lang('Modify').'" alt="" /></a>';
}else {
if($extension=='svg' && api_support_svg()){
if($extension=='svg' && api_browser_support('svg')){
$modify_icons = '<a href="edit_drawing.php?'.api_get_cidreq().'&curdirpath='.$curdirpath.'&amp;file='.urlencode($path).$req_gid.'"><img src="../img/edit.gif" border="0" title="'.get_lang('Modify').'" alt="" /></a>';
}else{
$modify_icons = '<a href="edit_document.php?'.api_get_cidreq().'&curdirpath='.$curdirpath.'&amp;file='.urlencode($path).$req_gid.'"><img src="../img/edit.gif" border="0" title="'.get_lang('Modify').'" alt="" /></a>';

@ -855,7 +855,7 @@ if ($is_allowed_to_edit || $group_member_with_upload_rights || is_my_shared_fold
<?php
// Create new draw
if (api_support_svg()){
if (api_browser_support('svg')){
?>
<a href="create_drawing.php?<?php echo api_get_cidreq(); ?>&dir=<?php echo $curdirpathurl.$req_gid; ?>">
<?php Display::display_icon('draw_new.png', get_lang('Draw')); echo get_lang('Draw'); ?></a>&nbsp;

@ -111,7 +111,7 @@ echo '<div class="actions">';
echo '<a href="document.php?curdirpath='.Security::remove_XSS($_GET['curdirpath']).'">'.Display::return_icon('back.png',get_lang('BackTo').' '.get_lang('DocumentsOverview')).get_lang('BackTo').' '.get_lang('DocumentsOverview').'</a>';
echo '</div>';
if (api_support_svg()){
if (api_browser_support('svg')){
//automatic loading the course language
$svgedit_code_translation_table = array('' => 'en', 'pt' => 'pt-Pt', 'sr' => 'sr_latn');

Binary file not shown.

After

Width:  |  Height:  |  Size: 30 KiB

@ -2053,6 +2053,7 @@ function fill_Db_course($course_db_name, $course_repository, $language, $default
}
global $_configuration, $_user;
$cdb = $course_db_name; //save it for plugins, later on
$course_db_name = $_configuration['table_prefix'].$course_db_name.$_configuration['db_glue'];
@ -2392,6 +2393,22 @@ function fill_Db_course($course_db_name, $course_repository, $language, $default
Database::query("INSERT INTO `$TABLEFORUMPOSTS` VALUES (1, '".lang2db(get_lang('ExampleThread'))."', '".lang2db(get_lang('ExampleThreadContent'))."', 1, 1, 1, '', NOW(), 0, 0, 1)");
}
// PLUGINS - if an installed plugin has a course_install.php file, execute it
$installed_plugins = api_get_settings('Plugins','list',$_configuration['access_url']);
$shortlist_installed = array();
foreach ($installed_plugins as $plugin) {
$shortlist_installed[] = $plugin['subkey'];
}
$shortlist_installed = array_flip(array_flip($shortlist_installed));
foreach ($shortlist_installed as $plugin) {
$pluginpath = api_get_path(SYS_PLUGIN_PATH).$plugin.'/course_install.php';
if (is_file($pluginpath) && is_readable($pluginpath)) {
//execute the install procedure
include $pluginpath;
}
}
//end of installed plugins alterations
$language_interface = $language_interface_tmp;

@ -151,6 +151,10 @@ class DocumentManager {
'mxu' => 'video/vnd.mpegurl',
'nc' => 'application/x-netcdf',
'oda' => 'application/oda',
'oga'=> 'audio/ogg',
'ogg'=> 'application/ogg',
'ogx'=> 'application/ogg',
'ogv'=> 'video/ogg',
'pbm' => 'image/x-portable-bitmap',
'pct' => 'image/pict',
'pdb' => 'chemical/x-pdb',
@ -197,7 +201,7 @@ class DocumentManager {
'sv4crc' => 'application/x-sv4crc',
'svf' => 'application/vnd.svf',
'svg' => 'image/svg+xml',
'svgz'=> 'image/svg+xml',
//'svgz' => 'image/svg+xml',
'swf' => 'application/x-shockwave-flash',
'sxc' => 'application/vnd.sun.xml.calc',
'sxi' => 'application/vnd.sun.xml.impress',

@ -41,17 +41,24 @@ class manager
array(array("zip", "sit", "rar", "gz", "tar"), "fileZip", SEARCH_TYPE_ARCHIVE, 0),
array(array("htm", "html", "php", "jsp", "asp", 'js', 'css'), "fileCode", SEARCH_TYPE_HTML, 1),
array(array("mov", "ram", "rm", "asx", "dcr", "wmv"), "fileVideo", SEARCH_TYPE_VIDEO, 1),
array(array("mpg", "avi", "asf", "mpeg"), "fileVideo", SEARCH_TYPE_MOVIE, 1),
array(array("aif", "aiff", "wav", "mp3", "wma","mid"), "fileMusic", SEARCH_TYPE_MUSIC, 1),
array(array("swf", 'flv'), "fileFlash", SEARCH_TYPE_FLASH, 1),
array(array("ppt"), "filePPT", SEARCH_TYPE_PPT, 0),
array(array("mpg", "avi", "asf", "mpeg", "flv", "mp4"), "fileVideo", SEARCH_TYPE_MOVIE, 1),
array(array("aif", "aiff", "wav", "mp3", "wma","mid", "midi"), "fileMusic", SEARCH_TYPE_MUSIC, 1),
array(array("swf", ), "fileFlash", SEARCH_TYPE_FLASH, 1),
array(array("ppt", "pps", "pptx"), "filePPT", SEARCH_TYPE_PPT, 0),
array(array("rtf"), "fileRTF", SEARCH_TYPE_DOC, 0),
array(array("doc"), "fileWord", SEARCH_TYPE_WORD, 0),
array(array("doc","docx"), "fileWord", SEARCH_TYPE_WORD, 0),
array(array("pdf"), "fileAcrobat", SEARCH_TYPE_PDF, 0),
array(array("xls", "csv"), "fileExcel", SEARCH_TYPE_EXCEL, 0),
array(array("xls", "xlsx", "csv"), "fileExcel", SEARCH_TYPE_EXCEL, 0),
array(array("txt"), "fileText", SEARCH_TYPE_TEXT, 1),
array(array("xml", "xsl", "dtd"), "fileXml", SEARCH_TYPE_XML, 1)
);
array(array("xml", "xsl", "dtd"), "fileXml", SEARCH_TYPE_XML, 1),
array(array("svg","svgz"), "fileSVG", SEARCH_TYPE_SVG, 1),
array(array("ogg", "ogx", "ogv", "oga"), "fileOGG", SEARCH_TYPE_OGG, 1),
array(array("odt", "ott", "sxw", "stw"), "fileODT", SEARCH_TYPE_ODT, 1),
array(array("odp", "otp", "sxi", "sti"), "fileODP", SEARCH_TYPE_ODP, 1),
array(array("ods", "ots", "sxc", "stc"), "fileODS", SEARCH_TYPE_ODS, 1),
array(array("odg", "otg", "sxd", "std"), "fileODG", SEARCH_TYPE_ODG, 1)
);// Added svg, svgz, pps, docx, pptx, xlsx, midi, ogg, ogv, oga,(odt,ods,odp,odg and extra) types to Chamilo, and change flv from flash to video
/**
* constructor

@ -159,14 +159,36 @@
define('CONFIG_EDITABLE_VALID_EXTS', 'txt,htm,html'); //make you include all these extension in CONFIG_UPLOAD_VALID_EXTS if you want all valid. For Chamilo exclude original xml, js and css
define('CONFIG_OVERWRITTEN', false); //overwirte when processing paste
define('CONFIG_UPLOAD_VALID_EXTS', 'gif,jpg,jpeg,png,bmp,tif,psd,zip,sit,rar,gz,tar,htm,html,mov,mpg,avi,asf,mpeg,wmv,aif,aiff,wav,mp3,swf, flv, mp4, aac, ppt,rtf,doc, pdf,xls,txt,flv,odt,ods,odp,odg,odc,odf,odb,odi,pps,docx,pptx,xlsx,accdb,xml, mid');//For Chamilo updated
define("CONFIG_VIEWABLE_VALID_EXTS", 'gif,bmp,txt,jpg,jpeg,png,tif,html,htm,mp3,wav,wmv,wma,rm,rmvb,mov,swf,flv,mp4,aac,avi,mpg,mpeg,asf,mid');//For Chamilo updated
define('CONFIG_UPLOAD_INVALID_EXTS', 'php,php3,php4,php5,php6,phps,phtml,asp,aspx,jsp,cfm,cfc,pl,jar,sh,cgi,js,exe,com,bat,pif,scr,msi,ws,wsc,wsf,vb,vbe,vbs,reg,dll'); //For Chamilo added.
define('CONFIG_UPLOAD_VALID_EXTS', 'gif,jpg,jpeg,png,bmp,tif,psd,zip,sit,rar,gz,tar,htm,html,mov,mpg,avi,asf,mpeg,wmv,ogg,ogx,ogv,oga, aif,aiff,wav,mp3,swf,flv, mp4, aac, ppt,rtf,doc, pdf,xls,txt,flv,odt,ods,odp,odg,odc,odf,odb,odi,pps,docx,pptx,xlsx,accdb,xml,mid, midi, svg, svgz');//For Chamilo updated
//define viewable valid exts
$viewable='gif,bmp,txt,jpg,jpeg,png,tif,html,htm,mp3,wav,wmv,wma,rm,rmvb,mov,swf,flv,mp4,aac,avi,mpg,mpeg,asf,mid,midi,pdf';//updated by Chamilo
$viewable_array = explode(" ",$viewable);
if (api_browser_support('svg')){
$viewable_array[]=',svg';
}
if (api_browser_support('ogg')){
$viewable_array[]=',ogg';
$viewable_array[]=',ogx';
$viewable_array[]=',oga';
$viewable_array[]=',ogv';
}
$viewable = implode(" ",$viewable_array);
$viewable = preg_replace('/\s+/', '', $viewable);//clean spaces
//print_r($viewable);
define("CONFIG_VIEWABLE_VALID_EXTS", $viewable);
//define invalid exts
define('CONFIG_UPLOAD_INVALID_EXTS', 'php,php3,php4,php5,php6,phps,phtml,asp,aspx,jsp,cfm,cfc,pl,jar,sh,cgi,js,exe,com,bat,pif,scr,msi,ws,wsc,wsf,vb,vbe,vbs,reg,dll,ini'); //For Chamilo added.
//Preview
define('CONFIG_IMG_THUMBNAIL_MAX_X', 100);
define('CONFIG_IMG_THUMBNAIL_MAX_Y', 100);
define('CONFIG_THICKBOX_MAX_WIDTH', 500);
define('CONFIG_THICKBOX_MAX_HEIGHT', 430);
define('CONFIG_THICKBOX_MAX_WIDTH', 400); //only for html, pdf, svg
define('CONFIG_THICKBOX_MAX_HEIGHT', 330);//only for html, pdf, svg
/**

@ -275,7 +275,9 @@ span.filePPT, span.fileExcel, span.filePhp,
span.fileMusic, span.fileExe, span.fileAcrobat,
span.fileRTF, span.fileXml, span.fileCode,
span.fileZip, span.addMore, span.deleteFile,
span.cancel,span.uploadProcessing, span.folderShared, span.unknownUser{
span.cancel,span.uploadProcessing,
span.folderShared, span.unknownUser, span.fileSVG,
span.fileODT,span.fileODS,span.fileODP,span.fileODG,span.fileOGG{
padding:2px 0 2px 16px;
background-repeat:no-repeat;
background-position:0 50%;
@ -305,6 +307,12 @@ span.fileZip{background-image:url(../images/small_icon/fileZip.png);}
span.folderShared{background-image:url(../images/small_icon/folderShared.png);}
span.unknownUser{background-image:url(../images/small_icon/smallunknownUser.png);}
span.fileSVG{background-image:url(../images/small_icon/fileSVG.png);}
span.fileODT{background-image:url(../images/small_icon/fileODT.png);}
span.fileODS{background-image:url(../images/small_icon/fileODS.png);}
span.fileODP{background-image:url(../images/small_icon/fileODP.png);}
span.fileODG{background-image:url(../images/small_icon/fileODG.png);}
span.fileOGG{background-image:url(../images/small_icon/fileOGG.png);}
/* big icon */
dt.folderEmpty, dt.folder, dt.folderParent,
@ -313,7 +321,9 @@ dt.fileFlash, dt.fileVideo,
dt.filePPT, dt.fileExcel, dt.filePhp,
dt.fileMusic, dt.fileExe, dt.fileAcrobat,
dt.fileRTF, dt.fileXml, dt.fileCode,
dt.fileZip,dt.folderShared, dt.unknownUser{
dt.fileZip,
dt.folderShared, dt.unknownUser, dt.fileSVG,
dt.fileODT,dt.fileODS,dt.fileODP,dt.fileODG,dt.fileOGG{
margin: 0px;
padding:0px;
border:solid #ccc 1px;
@ -348,7 +358,12 @@ dt.fileZip{background-image:url(../images/big_icon/fileZip.png);}
dt.folderShared{background-image:url(../images/big_icon/bigfolderShared.png);}
dt.unknownUser{background-image:url(../images/big_icon/biguserUnknown.png);}
dt.fileSVG{background-image:url(../images/big_icon/fileSVG.png);}
dt.fileODT{background-image:url(../images/big_icon/fileODT.png);}
dt.fileODS{background-image:url(../images/big_icon/fileODS.png);}
dt.fileODP{background-image:url(../images/big_icon/fileODP.png);}
dt.fileODG{background-image:url(../images/big_icon/fileODG.png);}
dt.fileOGG{background-image:url(../images/big_icon/fileOGG.png);}
table.tableSummary{
border-collapse:collapse;

@ -267,7 +267,9 @@ span.filePPT, span.fileExcel, span.filePhp,
span.fileMusic, span.fileExe, span.fileAcrobat,
span.fileRTF, span.fileXml, span.fileCode,
span.fileZip, span.addMore, span.deleteFile,
span.cancel,span.uploadProcessing, span.folderShared, span.unknownUser{
span.cancel,span.uploadProcessing,
span.folderShared, span.unknownUser, span.fileSVG,
span.fileODT,span.fileODS,span.fileODP,span.fileODG,span.fileOGG{
padding:2px 0 2px 16px;
background-repeat:no-repeat;
background-position:0 50%;
@ -297,6 +299,12 @@ span.fileZip{background-image:url(../images/small_icon/fileZip.png);}
span.folderShared{background-image:url(../images/small_icon/folderShared.png);}
span.unknownUser{background-image:url(../images/small_icon/smallunknownUser.png);}
span.fileSVG{background-image:url(../images/small_icon/fileSVG.png);}
span.fileODT{background-image:url(../images/small_icon/fileODT.png);}
span.fileODS{background-image:url(../images/small_icon/fileODS.png);}
span.fileODP{background-image:url(../images/small_icon/fileODP.png);}
span.fileODG{background-image:url(../images/small_icon/fileODG.png);}
span.fileOGG{background-image:url(../images/small_icon/fileOGG.png);}
/* big icon */
dt.folderEmpty, dt.folder, dt.folderParent,
@ -305,7 +313,9 @@ dt.fileFlash, dt.fileVideo,
dt.filePPT, dt.fileExcel, dt.filePhp,
dt.fileMusic, dt.fileExe, dt.fileAcrobat,
dt.fileRTF, dt.fileXml, dt.fileCode,
dt.fileZip,dt.folderShared, dt.unknownUser{
dt.fileZip,
dt.folderShared, dt.unknownUser, dt.fileSVG,
dt.fileODT,dt.fileODS,dt.fileODP,dt.fileODG,dt.fileOGG{
margin: 0px;
padding:0px;
border:solid #ccc 1px;
@ -340,7 +350,12 @@ dt.fileZip{background-image:url(../images/big_icon/fileZip.png);}
dt.folderShared{background-image:url(../images/big_icon/bigfolderShared.png);}
dt.unknownUser{background-image:url(../images/big_icon/biguserUnknown.png);}
dt.fileSVG{background-image:url(../images/big_icon/fileSVG.png);}
dt.fileODT{background-image:url(../images/big_icon/fileODT.png);}
dt.fileODS{background-image:url(../images/big_icon/fileODS.png);}
dt.fileODP{background-image:url(../images/big_icon/fileODP.png);}
dt.fileODG{background-image:url(../images/big_icon/fileODG.png);}
dt.fileOGG{background-image:url(../images/big_icon/fileOGG.png);}
table.tableSummary{
border-collapse:collapse;

@ -54,8 +54,8 @@ function choose_image($file_name)
$type['web' ] = array('htm', 'html', 'htx', 'xml', 'xsl', 'php', 'xhtml');
$type['image' ] = array('gif', 'jpg', 'png', 'bmp', 'jpeg');
$type['image_vect'] = array('svg','svgz');
$type['audio' ] = array('wav', 'mid', 'mp2', 'mp3', 'midi', 'sib', 'amr', 'kar');
$type['video' ] = array('mp4', 'mov', 'rm', 'pls', 'mpg', 'mpeg', 'au', 'flv', 'avi', 'wmv', 'asf', '3gp');
$type['audio' ] = array('wav', 'mid', 'mp2', 'mp3', 'midi', 'sib', 'amr', 'kar', 'oga');
$type['video' ] = array('mp4', 'mov', 'rm', 'pls', 'mpg', 'mpeg', 'au', 'flv', 'avi', 'wmv', 'asf', '3gp','ogv','ogg','ogx');
$type['excel' ] = array('xls', 'xlt', 'xls', 'xlt', 'pxl', 'xlsx', 'xlsm', 'xlam', 'xlsb', 'xltm', 'xltx');
$type['compressed'] = array('zip', 'tar', 'rar', 'gz');
$type['code' ] = array('js', 'cpp', 'c', 'java', 'phps');
@ -82,9 +82,6 @@ function choose_image($file_name)
$image['powerpoint'] = 'powerpoint.gif';
$image['flash' ] = 'file_flash.gif';
$image['text' ] = 'file_txt.gif';
//$image['oo_writer' ] = 'word.gif';
//$image['oo_calc' ] = 'excel.gif';
//$image['oo_impress'] = 'powerpoint.gif';
$image['oo_writer' ] = 'file_oo_writer.gif';
$image['oo_calc' ] = 'file_oo_calc.gif';
$image['oo_impress'] = 'file_oo_impress.gif';

@ -460,7 +460,13 @@ function add_ext_on_mime($file_name, $file_type) {
$mime_type[] = 'video/x-msvideo'; $extension[] = '.avi';
$mime_type[] = 'video/x-ms-wmv'; $extension[] = '.wmv';
$mime_type[] = 'video/x-flv'; $extension[] = '.flv';
$mime_type[] = 'video/x-flv'; $extension[] = '.flv';
$mime_type[] = 'image/svg+xml'; $extension[] = '.svg';
$mime_type[] = 'image/svg+xml'; $extension[] = '.svgz';
$mime_type[] = 'video/ogg'; $extension[] = '.ogv';
$mime_type[] = 'audio/ogg'; $extension[] = '.oga';
$mime_type[] = 'application/ogg'; $extension[] = '.ogg';
$mime_type[] = 'application/ogg'; $extension[] = '.ogx';
$mime_type[] = 'application/vnd.ms-word.document.macroEnabled.12'; $extension[] = '.docm';
$mime_type[] = 'application/vnd.openxmlformats-officedocument.wordprocessingml.document'; $extension[] = '.docx';

@ -5,7 +5,12 @@
* Licensed under the MIT License: http://www.opensource.org/licenses/mit-license.php
*/
var tb_pathToImage = "main/img/loadingAnimation.gif";
// Identify the url of the current script to load the loadingAnimation.gif animation
var src=document.getElementsByTagName('script');
var src=src[src.length-1].getAttribute('src');
// remove the inc/lib/javascript/thickbox.js part (30 characters)
var src=src.substr(0,src.length-30);
var tb_pathToImage = src+"img/loadingAnimation.gif";
/*!!!!!!!!!!!!!!!!! edit below this line at your own risk !!!!!!!!!!!!!!!!!!!!!!!*/

@ -4701,23 +4701,41 @@ function api_get_template($path_type = 'rel') {
/**
* Check browser support for svg files
** This function check if the users browser support a file format
* @param string $format
* @return bool
*
* @author Juan Carlos Raña Trabado
*/
function api_support_svg() {
function api_browser_support($format) {
require_once api_get_path(LIBRARY_PATH).'browser/Browser.php';
$browser = new Browser();
//print_r($browser);
$current_browser = $browser->getBrowser();
$a_versiontemp = explode('.', $browser->getVersion());
$current_majorver= $a_versiontemp[0];
if (($current_browser == 'Internet Explorer' && $current_majorver > 8) || ($current_browser == 'Firefox' && $current_majorver > 1) || ($current_browser == 'Safari' && $current_majorver >= 4) || ($current_browser == 'Chrome' && $current_majorver >= 1) || ($current_browser == 'Opera' && $current_majorver > 9)) {
return true;
} else {
return false;
}
if ($format=='svg'){
if (($current_browser == 'Internet Explorer' && $current_majorver > 8) || ($current_browser == 'Firefox' && $current_majorver > 1) || ($current_browser == 'Safari' && $current_majorver >= 4) || ($current_browser == 'Chrome' && $current_majorver >= 1) || ($current_browser == 'Opera' && $current_majorver > 9)) {
return true;
}
else {
return false;
}
}
elseif($format=='ogg'){
//native support
if (($current_browser == 'Firefox' && $current_majorver >= 3) || ($current_browser == 'Chrome' && $current_majorver >= 3)) {
return true;
}
else {
return false;
}
}
else{
return false;
}
}
/**

@ -271,11 +271,18 @@ function display_addedresource_link($type, $id, $style = '') {
$ext = explode('.', $filename);
$ext = strtolower($ext[sizeof($ext)-1]);
$myrow['path'] = rawurlencode($myrow['path']);
if (api_support_svg()){
$in_frames = in_array($ext, array('htm', 'html', 'gif', 'jpg', 'jpeg', 'png', 'svg','svgz'));
}else{
$in_frames = in_array($ext, array('htm', 'html', 'gif', 'jpg', 'jpeg', 'png'));
$array_ext=array('htm', 'html', 'gif', 'jpg', 'jpeg', 'png')
if (api_browser_support('svg')){
$array_ext[]='svg';
}
if (api_browser_support('ogg')){
$array_ext[]='ogg';
}
$in_frames = in_array($ext, $array_ext);
echo '<img src="../img/'.$image.'" align="middle" /> <a href="../document/'.($in_frames ? 'showinframes.php?file=' : 'download.php?doc_url=').$myrow['path'].'"'.$styling.'>'.$filename."</a><br />\n";
break;
case 'Externallink':

@ -231,7 +231,7 @@ function convert_date_to_number($default) {
$parts = split(' ', $default);
list($d_year, $d_month, $d_day) = split('-', $parts[0]);
list($d_hour, $d_minute, $d_second) = split(':', $parts[1]);
return mktime($d_hour, $d_minute, $d_second, $d_month, $d_day, $d_year);
return mktime((int)$d_hour, (int)$d_minute, (int)$d_second, (int)$d_month, (int)$d_day, (int)$d_year);
}
/**

@ -0,0 +1,6 @@
<?php
/**
* This script is included by the course_home.php script (indirectly) and is
* used to show the link to the plugin from inside the course's tools list
*/
echo "Videoconference";

@ -0,0 +1,14 @@
<?php
/**
* This script should be included by add_course.lib.inc.php when adding a new course
*/
//$cdb is defined inside the fillDbCourse() function which is calling this script
$t_course = Database::get_course_table(TABLE_COURSE_SETTING,$cdb);
$sql_course = "INSERT INTO $t_course (variable,value,category) VALUES ('big_blue_button_meeting_name','','plugins')";
$r = Database::query($sql_course);
$sql_course = "INSERT INTO $t_course (variable,value,category) VALUES ('big_blue_button_attendee_password','','plugins')";
$r = Database::query($sql_course);
$sql_course = "INSERT INTO $t_course (variable,value,category) VALUES ('big_blue_button_moderator_password','','plugins')";
$r = Database::query($sql_course);
$sql_course = "INSERT INTO $t_course (variable,value,category) VALUES ('big_blue_button_welcome_message','','plugins')";
$r = Database::query($sql_course);

@ -0,0 +1,3 @@
<?php
// should contain the code to access the plugin from outside a course
?>

@ -0,0 +1,41 @@
<?php
/**
* This script is included by main/admin/settings.lib.php and generally
* includes things to execute in the main database (settings_current table)
*/
$t_settings = Database::get_main_table(TABLE_MAIN_SETTINGS_CURRENT);
$t_options = Database::get_main_table(TABLE_MAIN_SETTINGS_OPTIONS);
$sql = "INSERT INTO $t_settings
(variable, subkey, type, category, selected_value, title, comment, scope, subkeytext, access_url_changeable)
VALUES
('bbb_plugin', '', 'radio', 'Extra', 'false', 'BigBlueButtonEnableTitle','BigBlueButtonEnableComment',NULL,NULL, 1)";
Database::query($sql);
$sql = "INSERT INTO $t_options (variable, value, display_text) VALUES ('bbb_plugin', 'true', 'Yes')";
Database::query($sql);
$sql = "INSERT INTO $t_options (variable, value, display_text) VALUES ('bbb_plugin', 'false', 'No')";
Database::query($sql);
$sql = "INSERT INTO $t_settings
(variable, subkey, type, category, selected_value, title, comment, scope, subkeytext, access_url_changeable)
VALUES
('bbb_plugin_host', '', 'textfield', 'Extra', '192.168.0.100', 'BigBlueButtonHostTitle','BigBlueButtonHostComment',NULL,NULL, 1)";
Database::query($sql);
$sql = "INSERT INTO $t_settings
(variable, subkey, type, category, selected_value, title, comment, scope, subkeytext, access_url_changeable)
VALUES
('bbb_plugin_salt', '', 'textfield', 'Extra', '', 'BigBlueButtonSecuritySaltTitle','BigBlueButtonSecuritySaltComment',NULL,NULL, 1)";
Database::query($sql);
// update existing courses to add conference settings
$t_courses = Database::get_main_table(TABLE_MAIN_COURSE);
$sql = "SELECT id, code, db_name FROM $t_courses ORDER BY id";
$res = Database::query($sql);
while ($row = Database::fetch_assoc($res)) {
$t_course = Database::get_course_table(TABLE_COURSE_SETTING,$row['db_name']);
$sql_course = "INSERT INTO $t_course (variable,value,category) VALUES ('big_blue_button_meeting_name','','plugins')";
$r = Database::query($sql_course);
$sql_course = "INSERT INTO $t_course (variable,value,category) VALUES ('big_blue_button_attendee_password','','plugins')";
$r = Database::query($sql_course);
$sql_course = "INSERT INTO $t_course (variable,value,category) VALUES ('big_blue_button_moderator_password','','plugins')";
$r = Database::query($sql_course);
$sql_course = "INSERT INTO $t_course (variable,value,category) VALUES ('big_blue_button_welcome_message','','plugins')";
$r = Database::query($sql_course);
}

@ -0,0 +1,20 @@
<?php
/**
* This script is a configuration file for the BigBlueButton plugin. You can use it as a master for other course plugins.
* These settings will be used in the administration interface for plugins (Chamilo configuration settings->Plugins)
* @package chamilo.plugin
* @author Yannick Warnier <ywarnier@beeznest.org>
*/
/**
* Plugin details (must be present)
*/
//the plugin title
$plugin_info['title']='BigBlueButton';
//the comments that go with the plugin
$plugin_info['comment']="Open Source Videoconference tool";
//the locations where this plugin can be shown
$plugin_info['location']=array('course_tool_plugin');
//the plugin version
$plugin_info['version']='0.9';
//the plugin author
$plugin_info['author']='Yannick Warnier';

@ -0,0 +1 @@
This plugin will create a link in existing and new courses for the teachers to start a videoconference room, as well as the administration settings to configure this tool.

@ -0,0 +1,31 @@
<?php
/**
* This script is included by main/admin/settings.lib.php when unselecting a plugin
* and is meant to remove things installed by the install.php script in both
* the global database and the courses tables
*/
$t_settings = Database::get_main_table(TABLE_MAIN_SETTINGS_CURRENT);
$t_options = Database::get_main_table(TABLE_MAIN_SETTINGS_OPTIONS);
$sql = "DELETE FROM $t_settings WHERE variable = 'bbb_plugin'";
Database::query($sql);
$sql = "DELETE FROM $t_options WHERE variable = 'bbb_plugin'";
Database::query($sql);
$sql = "DELETE FROM $t_settings WHERE variable = 'bbb_plugin_host'";
Database::query($sql);
$sql = "DELETE FROM $t_settings WHERE variable = 'bbb_plugin_salt'";
Database::query($sql);
// update existing courses to add conference settings
$t_courses = Database::get_main_table(TABLE_MAIN_COURSE);
$sql = "SELECT id, code, db_name FROM $t_courses ORDER BY id";
$res = Database::query($sql);
while ($row = Database::fetch_assoc($res)) {
$t_course = Database::get_course_table(TABLE_COURSE_SETTING,$row['db_name']);
$sql_course = "DELETE FROM $t_course WHERE variable = 'big_blue_button_meeting_name'";
$r = Database::query($sql_course);
$sql_course = "DELETE FROM $t_course WHERE variable = 'big_blue_button_attendee_password'";
$r = Database::query($sql_course);
$sql_course = "DELETE FROM $t_course WHERE variable = 'big_blue_button_moderator_password'";
$r = Database::query($sql_course);
$sql_course = "DELETE FROM $t_course WHERE variable = 'big_blue_button_welcome_message'";
$r = Database::query($sql_course);
}

@ -1,8 +1,8 @@
<?php //$id: $
/**
* This script is a configuration file for the date plugin. You can use it as a master for other plugins.
* These settings will be used in the administration interface for plugins (Dokeos configuration settings->Plugins)
* @package dokeos.plugin
* This script is a configuration file for the date plugin. You can use it as a master for other platform plugins (course plugins are slightly different).
* These settings will be used in the administration interface for plugins (Chamilo configuration settings->Plugins)
* @package chamilo.plugin
* @author Yannick Warnier <ywarnier@beeznest.org>
*/
/**

@ -1207,6 +1207,7 @@ if (!empty ($_GET['include']) && preg_match('/^[a-zA-Z0-9_-]*\.html$/',$_GET['in
$thisCoursePath = $my_course['d'];
$sys_course_path = api_get_path(SYS_COURSE_PATH);
$dbname = $my_course['k'];
$status = array();
$status[$dbname] = $my_course['s'];
$nbDigestEntries = 0; // Number of entries already collected.

Loading…
Cancel
Save