Juan Carlos Raña 14 years ago
parent
commit
d578f1cf12

+ 161 - 0
main/document/create_audio.php

@@ -0,0 +1,161 @@
+<?php
+/* For licensing terms, see /license.txt */
+
+/**
+ *	This file allows creating audio files from a text.
+ *
+ *	@package chamilo.document
+ *
+ * @author Juan Carlos Raña Trabado
+ * @since 8/janvier/2011
+ * TODO:clean all file and check lang for languages
+*/
+
+/*	INIT SECTION */
+
+// Name of the language file that needs to be included
+$language_file = array('document');
+
+require_once '../inc/global.inc.php';
+$_SESSION['whereami'] = 'document/createaudio';
+$this_section = SECTION_COURSES;
+
+require_once api_get_path(SYS_CODE_PATH).'document/document.inc.php';
+require_once api_get_path(LIBRARY_PATH).'groupmanager.lib.php';
+
+$nameTools = get_lang('CreateAudio');
+
+api_protect_course_script();
+api_block_anonymous_users();
+if (api_get_setting('enabled_text2audio') == 'false'){
+	api_not_allowed(true);
+}
+if (!isset($_GET['dir'])){
+	api_not_allowed(true);
+}
+
+$dir = isset($_GET['dir']) ? Security::remove_XSS($_GET['dir']) : Security::remove_XSS($_POST['dir']);
+$is_allowed_to_edit = api_is_allowed_to_edit(null, true);
+
+// Please, do not modify this dirname formatting
+
+if (strstr($dir, '..')) {
+	$dir = '/';
+}
+
+if ($dir[0] == '.') {
+	$dir = substr($dir, 1);
+}
+
+if ($dir[0] != '/') {
+	$dir = '/'.$dir;
+}
+
+if ($dir[strlen($dir) - 1] != '/') {
+	$dir .= '/';
+}
+
+$filepath = api_get_path(SYS_COURSE_PATH).$_course['path'].'/document'.$dir;
+
+if (!is_dir($filepath)) {
+	$filepath = api_get_path(SYS_COURSE_PATH).$_course['path'].'/document/';
+	$dir = '/';
+}
+
+//groups //TODO: clean
+if (isset ($_SESSION['_gid']) && $_SESSION['_gid'] != 0) {
+		$req_gid = '&amp;gidReq='.$_SESSION['_gid'];
+		$interbreadcrumb[] = array ("url" => "../group/group_space.php?gidReq=".$_SESSION['_gid'], "name" => get_lang('GroupSpace'));
+		$noPHP_SELF = true;
+		$to_group_id = $_SESSION['_gid'];
+		$group = GroupManager :: get_group_properties($to_group_id);
+		$path = explode('/', $dir);
+		if ('/'.$path[1] != $group['directory']) {
+			api_not_allowed(true);
+		}
+}
+
+$interbreadcrumb[] = array ("url" => "./document.php?curdirpath=".urlencode($_GET['dir']).$req_gid, "name" => get_lang('Documents'));
+
+if (!$is_allowed_in_course) {
+	api_not_allowed(true);
+}
+
+
+if (!($is_allowed_to_edit || $_SESSION['group_member_with_upload_rights'] || is_my_shared_folder($_user['user_id'], Security::remove_XSS($_GET['dir']),api_get_session_id()))) {
+	api_not_allowed(true);
+}
+
+
+/*	Header */
+event_access_tool(TOOL_DOCUMENT);
+$display_dir = $dir;
+if (isset ($group)) {
+	$display_dir = explode('/', $dir);
+	unset ($display_dir[0]);
+	unset ($display_dir[1]);
+	$display_dir = implode('/', $display_dir);
+}
+
+// Interbreadcrumb for the current directory root path
+	// Copied from document.php
+	$dir_array = explode('/', $dir);
+	$array_len = count($dir_array);
+	
+	
+	$dir_acum = '';
+	for ($i = 0; $i < $array_len; $i++) {
+		$url_dir = 'document.php?&curdirpath='.$dir_acum.$dir_array[$i];
+		//Max char 80
+		$url_to_who = cut($dir_array[$i],80);
+		if ($is_certificate_mode) {
+			$interbreadcrumb[] = array('url' => $url_dir.'&selectcat='.Security::remove_XSS($_GET['selectcat']), 'name' => $url_to_who);
+		} else {
+			$interbreadcrumb[] = array('url' => $url_dir, 'name' => $url_to_who);
+		}
+		$dir_acum .= $dir_array[$i].'/';
+	}
+//
+Display :: display_header($nameTools, 'Doc');
+
+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>';
+
+
+?>
+<div align="center">
+<?php Display::display_icon('sound.gif', get_lang('CreateAudio')); echo get_lang('HelpText2Audio'); ?>
+<form id="form1" name="form1" method="post" action="http://vozme.com/text2voice.php" target="mymp3" class="formw">
+  <p>
+    <label><?php echo get_lang('Language')?>: 
+      <select name="lang" id="select">
+        <option value="en" selected="selected">English</option>
+        <option value="es">Español</option>
+        <option value="pt">Português</option>
+        <option value="it">Italiano</option>        
+        <option value="ca">Català</option>
+        <option value="hi">हिन्दी</option>
+      </select>
+    </label>
+    <label><?php echo get_lang('Voice')?>:
+      <select name="gn" id="select1">
+        <option value="ml"><?php echo get_lang('Male')?></option>
+        <option value="fm"><?php echo get_lang('Female')?></option>
+      </select>
+    </label>
+  </p>
+  <div><?php echo get_lang('InsertText2Audio')?></div>
+  <p>
+    <label>
+      <textarea name="text" id="textarea" cols="55" rows="6"></textarea>
+    </label>
+  </p>
+  <p>
+    <button class="save" type="submit" name="SendText2Audio"><?php echo get_lang('BuildMP3');?></button>
+  </p>
+</form>
+</div>
+<?php
+Display :: display_footer();
+?>

+ 9 - 8
main/document/document.inc.php

@@ -238,13 +238,7 @@ function build_document_icon_tag($type, $path) {
 			} else {
 				$basename = get_lang('UserFolders');
 			}
-		}elseif(strstr($path, 'shared_folder_session_')) {
-			if ($is_allowed_to_edit) {
-				$basename = '***('.api_get_session_name($current_session_id).')*** '.get_lang('HelpUsersFolder');
-			} else {
-				$basename = get_lang('UserFolders').' ('.api_get_session_name($current_session_id).')';
-			}
-			$icon = 'folder_users.gif';
+		
 		}elseif(strstr($basename, 'sf_user_')) {
 			$userinfo = Database::get_user_info_from_id(substr($basename, 8));
 			$image_path = UserManager::get_user_picture_path_by_id(substr($basename, 8), 'web', false, true);
@@ -255,7 +249,14 @@ function build_document_icon_tag($type, $path) {
 				$icon = '../upload/users/'.substr($basename, 8).'/'.$image_path['file'];
 			}
 
-			$basename = get_lang('UserFolder').' '.api_get_person_name($userinfo['firstname'], $userinfo['lastname']);
+			$basename = get_lang('UserFolder').' '.api_get_person_name($userinfo['firstname'], $userinfo['lastname']);}elseif(strstr($path, 'shared_folder_session_')) {
+			if ($is_allowed_to_edit) {
+				$basename = '***('.api_get_session_name($current_session_id).')*** '.get_lang('HelpUsersFolder');
+			} else {
+				$basename = get_lang('UserFolders').' ('.api_get_session_name($current_session_id).')';
+			}
+			$icon = 'folder_users.gif';
+			
 		} else {
 			$icon = 'folder_document.gif';
 			

+ 10 - 2
main/document/document.php

@@ -232,7 +232,7 @@ $current_session_id = api_get_session_id();
 if($current_session_id==0){
 	//Create shared folder. Necessary for courses recycled. Allways session_id should be zero. Allway should be created from a base course, never from a session.
 	if (!file_exists($base_work_dir.'/shared_folder')) {
-		$usf_dir_title = get_lang('SharedFolder');
+		$usf_dir_title = get_lang('UserFolders');
 		$usf_dir_name = '/shared_folder';
 		$to_group_id = 0;
 		$visibility = 0;
@@ -250,7 +250,7 @@ if($current_session_id==0){
 else{	
 		//Create shared folder session
 		if (!file_exists($base_work_dir.'/shared_folder_session_'.$current_session_id)) {
-			$usf_dir_title = get_lang('SharedFolder').' ('.api_get_session_name($current_session_id).')';
+			$usf_dir_title = get_lang('UserFolders').' ('.api_get_session_name($current_session_id).')';
 			$usf_dir_name = '/shared_folder_session_'.$current_session_id;			
 			$to_group_id = 0;
 			$visibility = 0;
@@ -928,6 +928,14 @@ if ($is_allowed_to_edit || $group_member_with_upload_rights || is_my_shared_fold
 		}
 	}
 	
+	// Create new audio
+	//if (api_get_setting('enabled_text2audio') == 'true'){
+	?>
+		<a href="create_audio.php?<?php echo api_get_cidreq(); ?>&dir=<?php echo $curdirpathurl.$req_gid; ?>">
+       <?php Display::display_icon('new_text2audio.png', get_lang('CreateAudio')); echo get_lang('CreateAudio'); ?></a>&nbsp;
+	<?php
+   // }	
+
 	// Create new certificate
 	if ($is_certificate_mode) {
 ?>

BIN
main/img/new_text2audio.png


+ 3 - 3
main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/ajaxfilemanager.php

@@ -94,14 +94,14 @@
 	var paths = {'root':'<?php echo addTrailingSlash(backslashToSlash(CONFIG_SYS_ROOT_PATH)); ?>', 'root_title':'<?php echo LBL_FOLDER_ROOT; ?>'};
 	
 	<!-- Chamilo hack for breadcrumb into shared folders -->
-	var shared_folder = '<?php echo get_lang('SharedDocumentsDirectory');?>';
+	var shared_folder = '<?php echo get_lang('UserFolders');?>';
 	
 	<?php 
 	$course_session = explode('_', basename($currentPath));
 	$course_session = strtolower($course_session[sizeof($course_session) - 1]);
 	?>
-	<!--var shared_folder_session = '<?php //echo get_lang('SharedDocumentsDirectory').' ('.api_get_session_name($course_session).')';?>'; --><!--// problem does not refresh, does not synchronize with javascript -->
-	var shared_folder_session = '<?php echo get_lang('SharedDocumentsDirectory').'*';?>';
+	<!--var shared_folder_session = '<?php //echo get_lang('UserFolders').' ('.api_get_session_name($course_session).')';?>'; --><!--// problem does not refresh, does not synchronize with javascript -->
+	var shared_folder_session = '<?php echo get_lang('UserFolders').'*';?>';
 	<?php 
 	
 	//$userinfo=Database::get_user_info_from_id(substr(basename($folderInfo['path']), 8));	// problem with $folderInfo['path'] does not refresh, sincronisation with javascript?>

+ 2 - 2
main/inc/lib/fckeditor/editor/plugins/ajaxfilemanager/inc/class.manager.php

@@ -114,13 +114,13 @@ class manager
 				}				
 				if(preg_match('/shared_folder/', basename($this->currentFolderPath)))
 				{
-					$this->currentFolderInfo['name']=get_lang('SharedDocumentsDirectory');
+					$this->currentFolderInfo['name']=get_lang('UserFolders');
 				}
 				if(preg_match('/shared_folder_session_/',basename($this->currentFolderPath)))
 				{
 					$session = explode('_', basename($this->currentFolderPath));
 					$session = strtolower($session[sizeof($session) - 1]);
-					$this->currentFolderInfo['name']=get_lang('SharedDocumentsDirectory').' ('.api_get_session_name($session).')*';
+					$this->currentFolderInfo['name']=get_lang('UserFolders').' ('.api_get_session_name($session).')*';
 				}
 			
 				//end Chamilo

+ 6 - 6
main/inc/lib/fckeditor/editor/plugins/insertHtml/lang/en.js

@@ -1,6 +1,6 @@
-
-
-	FCKLang.inserHTML_buttonTooltip					= 'Insert HTML';
-	FCKLang.insertHtml_dialogTitle						= 'Insert HTML';
-	FCKLang.inserHtml_help								= 'Enter any HTML below and click \'ok\' to insert it at the location of the cursor in the editor.';
-
+
+
+	FCKLang.inserHTML_buttonTooltip					= 'Insert Widget';
+	FCKLang.insertHtml_dialogTitle						= 'Insert Widget';
+	FCKLang.inserHtml_help								= 'Enter any HTML below and click \'ok\' to insert it at the location of the cursor in the editor.';
+

+ 3 - 3
main/inc/lib/fckeditor/editor/plugins/insertHtml/lang/es.js

@@ -1,6 +1,6 @@
 
 
-	FCKLang.inserHTML_buttonTooltip					= 'Insertar HTML';
-	FCKLang.insertHtml_dialogTitle						= 'Insertar HTML';
-	FCKLang.inserHtml_help								= 'Introduzca cualquier código HTML debajo y haga clic \'ok\' para insertarlo en la posición en la que se encuentra el cursos en el editor.';
+	FCKLang.inserHTML_buttonTooltip					= 'Insertar Widget';
+	FCKLang.insertHtml_dialogTitle						= 'Insertar Widget';
+	FCKLang.inserHtml_help								= 'Introduzca cualquier código HTML debajo y haga clic \'ok\' para insertarlo en la posición en la que se encuentra el cursor en el editor.';
 

+ 5 - 5
main/inc/lib/fckeditor/editor/plugins/insertHtml/lang/nl.js

@@ -1,5 +1,5 @@
-
-
-	FCKLang.inserHTML_buttonTooltip					= 'HTML invoegen';
-	FCKLang.insertHtml_dialogTitle						= 'HTML invoegen';
-	FCKLang.inserHtml_help								= 'Geef HTML code in en klik op \'ok\' om de code in te voegen op de locatie van de cursor in de editor.';
+
+
+	FCKLang.inserHTML_buttonTooltip					= 'Widget invoegen';
+	FCKLang.insertHtml_dialogTitle						= 'Widget invoegen';
+	FCKLang.inserHtml_help								= 'Geef HTML code in en klik op \'ok\' om de code in te voegen op de locatie van de cursor in de editor.';

+ 3 - 3
main/inc/lib/fckeditor/toolbars/extended/wiki.php

@@ -23,9 +23,9 @@ else{
 $config['ToolbarSets']['Normal'] = array(
 	array('Save','NewPage','Templates','-','PasteText'),
 	array('Undo','Redo'),
-	array('Wikilink','Link','Image','flvPlayer','Table','mimetex'),
+	array('Wikilink','Link','Image','flvPlayer','Table','mimetex','asciimath','asciisvg'),
 	array('UnorderedList','OrderedList','Rule','-','Outdent','Indent'),
-	array('JustifyLeft','JustifyCenter','JustifyRight','JustifyFull'),
+	array('JustifyLeft','JustifyCenter','JustifyFull'),
 	array('FontFormat','FontName','FontSize','Bold','Italic','Underline','TextColor','BGColor'),
 	array('FitWindow')
 );
@@ -38,7 +38,7 @@ $config['ToolbarSets']['Maximized'] = array(
 	array('Cut','Copy','Paste','PasteText','PasteWord'),
 	array('Undo','Redo','-','SelectAll','Find','-','RemoveFormat'),
 	array('Wikilink','Link','Unlink','Anchor','Glossary'),
-	array('Image','imgmapPopup','flvPlayer','EmbedMovies','YouTube','Flash','MP3','googlemaps','Smiley','SpecialChar','insertHtml','mimetex','fckeditor_wiris_openFormulaEditor','fckeditor_wiris_openCAS'),
+	array('Image','imgmapPopup','flvPlayer','EmbedMovies','YouTube','Flash','MP3','googlemaps','Smiley','SpecialChar','insertHtml','mimetex','asciimath','asciisvg','fckeditor_wiris_openFormulaEditor','fckeditor_wiris_openCAS'),
 '/',
 	array('Table','TableInsertRowAfter','TableDeleteRows','TableInsertColumnAfter','TableDeleteColumns','TableInsertCellAfter','TableDeleteCells','TableMergeCells','TableHorizontalSplitCell','TableVerticalSplitCell','TableCellProp','-','CreateDiv'),
 	array('UnorderedList','OrderedList','Rule','-','Outdent','Indent','Blockquote'),

+ 3 - 3
main/inc/lib/fckeditor/toolbars/extended/wiki_student.php

@@ -22,11 +22,11 @@ else{
 
 // This is the visible toolbar set when the editor has "normal" size.
 $config['ToolbarSets']['Normal'] = array(
-array('Save','NewPage','Templates','-','PasteText'),
+	array('Save','NewPage','Templates','-','PasteText'),
 	array('Undo','Redo'),
-	array('Wikilink','Link','Image','flvPlayer','Table','mimetex'),
+	array('Wikilink','Link','Image','flvPlayer','Table','mimetex','asciimath','asciisvg'),
 	array('UnorderedList','OrderedList','Rule','-','Outdent','Indent'),
-	array('JustifyLeft','JustifyCenter','JustifyRight','JustifyFull'),
+	array('JustifyLeft','JustifyCenter','JustifyFull'),
 	array('FontFormat','FontName','FontSize','Bold','Italic','Underline','TextColor','BGColor'),
 	array('FitWindow')
 );

+ 6 - 2
main/install/db_main.sql

@@ -788,7 +788,9 @@ VALUES
 ('show_users_folders',				NULL,'radio',		'Tools',	'true',	'ShowUsersFoldersTitle','ShowUsersFoldersComment',NULL,NULL, 0),
 ('show_default_folders',				NULL,'radio',		'Tools',	'true',	'ShowDefaultFoldersTitle','ShowDefaultFoldersComment',NULL,NULL, 0),
 ('show_chat_folder',				NULL,'radio',		'Tools',	'true',	'ShowChatFolderTitle','ShowChatFolderComment',NULL,NULL, 0),
-('chamilo_database_version', 		NULL,'textfield', 	NULL, '1.8.8.13255','DokeosDatabaseVersion','', NULL, NULL, 0);
+'ShowDefaultFoldersTitle','ShowDefaultFoldersComment',NULL,NULL, 0),
+('enabled_text2audio',				NULL,'radio',		'Tools',	'false',	'Text2AudioTitle','Text2AudioComment',NULL,NULL, 0),
+('chamilo_database_version', 		NULL,'textfield', 	NULL, '1.8.8.13256','DokeosDatabaseVersion','', NULL, NULL, 0);
 
 
 UNLOCK TABLES;
@@ -1038,7 +1040,9 @@ VALUES
 ('show_default_folders','true','Yes'),
 ('show_default_folders','false','No'),
 ('show_chat_folder','true','Yes'),
-('show_chat_folder','false','No');
+('show_chat_folder','false','No'),
+('enabled_text2audio','true','Yes'),
+('enabled_text2audio','false','No');
 
 UNLOCK TABLES;
 

+ 4 - 5
main/install/migrate-db-1.8.7-1.8.8-pre.sql

@@ -82,7 +82,7 @@ INSERT INTO settings_current (variable, subkey, type, category, selected_value,
 INSERT INTO settings_options (variable, value, display_text) VALUES ('pdf_export_watermark_by_course','true','Yes');
 INSERT INTO settings_options (variable, value, display_text) VALUES ('pdf_export_watermark_by_course','false','No');
 
-INSERT INTO settings_current (variable, subkey, type, category, selected_value, title, comment, scope, subkeytext, access_url_changeable) VALUES ('pdf_export_watermark_text',		NULL,'textfield',	'Platform',	'',		'PDFExportWatermarkTextTitle',		'PDFExportWatermarkTextComment','platform',NULL, 	1);
+INSERT INTO settings_current (variable, subkey, type, category, selected_value, title, comment, scope, subkeytext, access_url_changeable) VALUES ('pdf_export_watermark_text',		NULL,'textfield',	'Platform',	'',		'PDFExportWatermarkTextTitle','PDFExportWatermarkTextComment','platform',NULL, 	1);
 
 
 ALTER TABLE personal_agenda ADD PRIMARY KEY (id);
@@ -112,10 +112,9 @@ INSERT INTO settings_current (variable, subkey, type, category, selected_value,
 INSERT INTO settings_options (variable, value, display_text) VALUES ('show_chat_folder', 'true', 'Yes');
 INSERT INTO settings_options (variable, value, display_text) VALUES ('show_chat_folder', 'false', 'No');
 
-
-
-
-
+INSERT INTO settings_current (variable, subkey, type, category, selected_value, title, comment, scope, subkeytext, access_url_changeable) VALUES ('enabled_text2audio',NULL,'radio','Tools','false','Text2AudioTitle','Text2AudioComment',NULL,NULL, 0);
+INSERT INTO settings_options (variable, value, display_text) VALUES ('enabled_text2audio', 'true', 'Yes');
+INSERT INTO settings_options (variable, value, display_text) VALUES ('enabled_text2audio', 'false', 'No');
 
 
 -- xxSTATSxx

+ 13 - 0
main/lang/english/admin.inc.php

@@ -1311,4 +1311,17 @@ $BigBlueButtonSecuritySaltTitle = "Security key of the BigBlueButton server";
 $BigBlueButtonSecuritySaltComment = "This is the security key of your BigBlueButton server, which will allow your server to authentify the Chamilo installation. Refer to the BigBlueButton documentation to locate it.";
 $AsciiSvgTitle = "Mathematical graphics editor ASCIIsvg";
 $AsciiSvgComment = "Activation of mathematical graphics editor (ASCIIsvg).";
+$Text2AudioTitle = "
+Enable online services to conversion text in audio";
+$Text2AudioComment = "vozMe: From text to speech. Online tool to convert text into speech. vozMe uses speech synthesis systems and technology to provide voice resources.";
+$ShowUsersFoldersTitle = "Show users folders in the documents tool";
+$ShowUsersFoldersComment = "This option allows you to show or hide to teachers the folders that the system generates for each user who visits the tool documents or send a file through the web editor. If you display these folders to the teachers, they may make visible or not the students and allow each student to have a specific place on the course where not only store documents, but where they can also create and edit web pages and to export to pdf, make drawings, make personal web templates, send files, as well as create, move and delete directories and files and make security copies from their folders. Each user of course have a complete document manager. Also, remember that any user can copy a file that is visible from any folder in the documents tool (whether or not the owner) to his/her portfolios or personal documents area of social network, which will be available for his/her can use it in other courses.";
+$ShowDefaultFoldersTitle = "Show in documents tool all folders containing multimedia resources supplied by default";
+$ShowDefaultFoldersComment = "Multimedia file folders containing files supplied by default organized in categories of video, audio, image and flash animations to use in their courses. Although you make it invisible into the document tool, you can still use these resources in the platform web editor.";
+$ShowChatFolderTitle = "Show the history folder of chat conversations";
+$ShowChatFolderComment = "This will show to theacher the folder that contains all sessions that have been made in the chat, the teacher can make them visible or not students and use them as a resource";
+$EnabledStudentExport2PDFTitle = "Allow students to export web documents to PDF format in the documents and wiki tools";
+$EnabledStudentExport2PDFComment = "This feature is enabled by default, but in case of server overload abuse it, or specific learning environments, might want to disable it for all courses.";
+$EnabledInsertHtmlTitle = "Allow the insertion of widgets";
+$EnabledInsertHtmlComment = "This allows you to embed on your webpages your favorite videos and applications such as vimeo or slideshare and all sorts of widgets and gadgets";
 ?>

+ 10 - 3
main/lang/english/document.inc.php

@@ -234,13 +234,13 @@ $HelpUsersFolder = "VISIBLE INFORMATION ONLY FOR THE TEACHER:
 
 The folder of users contains a folder for each user who has accessed it through the tool documents, or when any file has been sent to the course through the editor. If neither circumstances there has been no user folder is created. In the case of groups, files that are sent to through the editor shall be deposited in the folder for each group, which is only accessible by students from tool groups.
 
-The user folder and folders that contains each of them,will be hidden by default in documentation tool for all students, but each student can see the contents of his/hers property access the editor. However, if a student knows the address of a file folder of another student may watch it.
+The user folder and folders that contains each of them,will be hidden by default in documentation tool for all students, but each student can see the contents of his/her property access the editor. However, if a student knows the address of a file folder of another student may watch it.
 
-If this folder and the folder of one or more students is visible to users, other students can see what they contain. In this case, the student that owns the folder from the documents tool can also (only in his/hers folder): create and edit web documents, convert a document into a template web for personal use, create and edit drawings svg and png, send documents, create folders, move folders and files, delete folders and files, and download backup of his/hers folder.
+If this folder and the folder of one or more students is visible to users, other students can see what they contain. In this case, the student that owns the folder from the documents tool can also (only in his/her folder): create and edit web documents, convert a document into a template web for personal use, create and edit drawings svg and png, send documents, create folders, move folders and files, delete folders and files, and download backup of his/her folder.
 
 Moreover, the documents tool is synchronized with the file manager of the web editor, so changes in the management of documents produced in one or another will affect both.
 
-Thus, the user folder is not only a place to deposit files, it becomes a complete manager of the documents that students use during the course. Also, remember that any user can copy a file that is visible from any folder in the documents tool (whether or not the owner) to his/hers portfolios or personal documents area of social network, which will be available for his/hers can use it in other courses.";
+Thus, the user folder is not only a place to deposit files, it becomes a complete manager of the documents that students use during the course. Also, remember that any user can copy a file that is visible from any folder in the documents tool (whether or not the owner) to his/her portfolios or personal documents area of social network, which will be available for his/her can use it in other courses.";
 $HelpFolderChat = "VISIBLE INFORMATION ONLY FOR THE TEACHER: 
 
 This folder contains all sessions that have been made in the chat. Although often in the chat sessions can be trivial, others can be really interesting and worthy of being incorporated as a document more work. To do this, without changing the visibility of this folder, link the file and make it visible where deemed appropriate. Not recommended this folder visible.";
@@ -248,4 +248,11 @@ $HelpFolderCertificates = "VISIBLE INFORMATION ONLY FOR THE TEACHER:
 
 This folder contains the various models of certificates that have been created for the rating tool. No it is recommended that this folder visible.";
 $DestinationDirectory = "Destination folder";
+$CreateAudio = "Create audio";
+$InsertText2Audio = "Enter the text you want to convert an audio file";
+$HelpText2Audio = "Transform your text into speech";
+$BuildMP3 = "Build mp3";
+$Voice = "Voice";
+$Female = "Female";
+$Male = "Male";
 ?>

+ 10 - 0
main/lang/galician/admin.inc.php

@@ -1293,4 +1293,14 @@ $EnabledWirisTitle = "Editor matemático WIRIS";
 $EnabledWirisComment = "Habilitar o editor matemático WIRIS";
 $AllowSpellCheckTitle = "Corrector ortográfico";
 $AllowSpellCheckComment = "Activar o corrector ortográfico";
+$EnabledSVGTitle = "Creación e edición de arquivos SVG";
+$EnabledSVGComment = "Esta opción permitiralle crear e editar arquivos SVG (Gráficos vectoriais escalables) multicapa en liña, así como exportalos a imaxes en formato PNG.";
+$ForceWikiPasteAsPlainTextTitle = "Obrigar a pegar como texto plano no Wiki";
+$ForceWikiPasteAsPlainTextComment = "Isto impedirá que moitas etiquetas ocultas, incorrectas ou non estándar, copiadas de outros textos rematen corrompendo o texto do Wiki despois de moitas edicións; pero perderá algunhas posibilidades durante a edición.";
+$EnabledGooglemapsTitle = "Activar Google maps";
+$EnabledGooglemapsComment = "Activar o botón para inserir mapas de Google. A activación non se realizará completamente se previamente non editou o arquivo main/inc/lib/fckeditor/myconfig.php e engadido unha clave API de Google maps.";
+$EnabledImageMapsTitle = "Activar mapas de imaxe";
+$EnabledImageMapsComment = "Activar o botón para inserir mapas de imaxe. Isto permitiralle asociar direccións url a zonas dunha imaxe, xenerando zonas interactivas";
+$CourseTool = "Ferramenta do curso";
+$BigBlueButtonEnableTitle = "Ferramenta de videoconferencia BigBlueButton";
 ?>

+ 2 - 0
main/lang/italian/admin.inc.php

@@ -1319,4 +1319,6 @@ $BigBlueButtonHostTitle = "Host del server BigBlueButton";
 $BigBlueButtonHostComment = "Nome del server in cui BigBlueButton è installato. Può essere localhost, oppure un indirizzo IP (es. 192.168.13.54) o ancora un nome di dominio (es. my.video.com)";
 $BigBlueButtonSecuritySaltTitle = "Chiave di sicurezza del server BigBlueButton";
 $BigBlueButtonSecuritySaltComment = "La Chiave di sicurezza del server BigBlueButton  consente l'autenticazione della piattaforma Chamilo presso il server (v. documentazione di BigBlueButton )";
+$AsciiSvgTitle = "Editor grafici matematici ASCIIsvg";
+$AsciiSvgComment = "Attivazione dell'editor di grafici matematici ASCIIsvg";
 ?>

+ 15 - 0
main/lang/spanish/admin.inc.php

@@ -1311,4 +1311,19 @@ $BigBlueButtonHostTitle = "Servidor BigBlueButton";
 $BigBlueButtonHostComment = "Este es el nombre del servidor donde su servidor BigBlueButton está ejecutándose. Puede ser localhost, una dirección IP (ej., 192.168.14.54) o un nombre de dominio (por ej., my.video.com).";
 $BigBlueButtonSecuritySaltTitle = "Clave de seguridad del servidor BigBlueButton";
 $BigBlueButtonSecuritySaltComment = "Esta es la clave de seguridad de su servidor BigBlueButton, que permitirá a su servidor autentificar la instalación Chamilo. Consulte la documentación de BigBlueButton para localizarla.";
+$AsciiSvgTitle = "Editor de gráficos matemáticos ASCIIsvg";
+$AsciiSvgComment = "Activación del editor de gráficos matemáticos (ASCIIsvg)";
+$Text2AudioTitle = "Activar servicios de conversión de texto en audio";
+$Text2AudioComment = "vozMe: De texto a voz. Herramienta on-line para convertir texto en voz. vozMe utiliza tecnología y sistemas de síntesis del habla para ofrecer recursos de voz";
+$ShowUsersFoldersTitle = "Mostrar las carpetas de los usuarios en la herramienta documentos";
+$ShowUsersFoldersComment = "
+Esta opción le permitirá mostrar u ocultar a los profesores las carpetas que el sistema genera para cada usuario que visita la herramienta documentos o envía un archivo a través del editor web. Si muestra estas carpetas a los profesores, éstos podrán hacerlas visibles o no a los estudiantes y permitirán a cada estudiante tener un lugar específico en el curso donde, no sólo almacenar documentos, sino donde también podrán crear y modificar páginas web y poder exportarlas a pdf, realizar dibujos, realizar plantillas web personales, enviar archivos, así como crear, mover y eliminar subdirectorios y archivos, y sacar copias de seguridad de sus carpetas. Cada usuario del curso dispondrá de un completo gestor de documentos. Además, recuerde que cualquier usuario podrá copiar un archivo, que sea visible, de cualquier carpeta de la herramienta documentos (sea o no la suya) a su portafolios o área personal de documentos de la red social, donde estará disponible para que lo pueda usar en otros cursos.";
+$ShowDefaultFoldersTitle = "Mostrar en la herramienta documentos las carpetas que contienen los recursos multimedia suministrados por defecto.";
+$ShowDefaultFoldersComment = "Las carpetas de archivos multimedia suministradas por defecto contienen archivos de libre distribución organizados en las categorías de video, audio, imagen y animaciones flash que para utilizar en sus cursos. Aunque las oculte en la herramienta documentos, podrá seguir usándolas en el editor web de la plataforma.";
+$ShowChatFolderTitle = "Mostrar la carpeta del historial de las conversaciones del chat";
+$ShowChatFolderComment = "Esto mostrará al profesorado la carpeta que contiene todas las sesiones que se han realizado en el chat, pudiendo éste hacerlas visibles o no a los estudiantes y utilizarlas como un recurso más.";
+$EnabledStudentExport2PDFTitle = "Permitir a los estudiantes exportar documentos web al formato PDF en las herramientas documentos y wiki";
+$EnabledStudentExport2PDFComment = "Esta prestación está habilitada por defecto, pero en caso de sobrecarga del servidor por abuso de ella, o en entornos de formación específicos, puede que desee dsactivarla en todos los cursos.";
+$EnabledInsertHtmlTitle = "Permitir la inserción de Widgets";
+$EnabledInsertHtmlComment = "Esto le permitirá embeber en sus páginas web sus videos y aplicaciones favoritas como vimeo o slideshare y todo tipo de widgets y gadgets";
 ?>

+ 7 - 0
main/lang/spanish/document.inc.php

@@ -248,4 +248,11 @@ $HelpFolderCertificates = "INFORMACIÓN VISIBLE SÓLO POR EL PROFESORADO:
 
 Esta carpeta contiene los distintos modelos de certificados que se han creado para la herramienta Evaluaciones. No se recomienda hacer visible esta carpeta.";
 $DestinationDirectory = "Carpeta de destino";
+$CreateAudio = "Crear audio";
+$InsertText2Audio = "Introduzca el texto que desea convertir en un archivo de audio";
+$HelpText2Audio = "Transforme su texto en voz";
+$BuildMP3 = "Generar mp3";
+$Voice = "Voz";
+$Female = "Femenina";
+$Male = "Masculina";
 ?>

+ 48 - 20
main/newscorm/learnpath.class.php

@@ -1649,9 +1649,9 @@ class learnpath {
             '  <tr> ' . "\n" .
             '    <td>' . "\n" .
             '      <div class="buttons">' . "\n" .
-            '        <a href="lp_controller.php?action=stats" onclick="window.parent.API.save_asset();return true;" target="content_name_blank" title="stats" id="stats_link"><img border="0" src="../img/lp_stats.gif" title="' . get_lang('Reporting') . '"></a>' . "\n" .
-            '        <a href="" onclick="switch_item(' . $mycurrentitemid . ',\'previous\');return false;" title="previous"><img border="0" src="../img/lp_leftarrow.gif" title="' . get_lang('ScormPrevious') . '"></a>' . "\n" .
-            '        <a href="" onclick="switch_item(' . $mycurrentitemid . ',\'next\');return false;" title="next"  ><img border="0" src="../img/lp_rightarrow.gif" title="' . get_lang('ScormNext') . '"></a>' . "\n" .
+            '        <a href="lp_controller.php?action=stats" onClick="window.parent.API.save_asset();return true;" target="content_name_blank" title="stats" id="stats_link"><img border="0" src="../img/lp_stats.gif" title="' . get_lang('Reporting') . '"></a>' . "\n" .
+            '        <a href="" onClick="switch_item(' . $mycurrentitemid . ',\'previous\');return false;" title="previous"><img border="0" src="../img/lp_leftarrow.gif" title="' . get_lang('ScormPrevious') . '"></a>' . "\n" .
+            '        <a href="" onClick="switch_item(' . $mycurrentitemid . ',\'next\');return false;" title="next"  ><img border="0" src="../img/lp_rightarrow.gif" title="' . get_lang('ScormNext') . '"></a>' . "\n" .
             //'        <a href="lp_controller.php?action=mode&mode=embedded" target="_top" title="embedded mode"><img border="0" src="../img/view_choose.gif" title="'.get_lang('ScormExitFullScreen').'"></a>'."\n" .
             //'        <a href="lp_controller.php?action=list" target="_top" title="learnpaths list"><img border="0" src="../img/exit.png" title="Exit"></a>'."\n" .
             '      </div>' . "\n" .
@@ -1664,9 +1664,9 @@ class learnpath {
             '  <tr> ' . "\n" .
             '    <td>' . "\n" .
             '      <div class="buttons">' . "\n" .
-            '        <a href="lp_controller.php?action=stats" onclick="window.parent.API.save_asset();return true;" target="content_name" title="stats" id="stats_link"><img border="0" src="../img/lp_stats.gif" title="' . get_lang('Reporting') . '"></a>' . "\n" .
-            '        <a href="" onclick="switch_item(' . $mycurrentitemid . ',\'previous\');return false;" title="previous"><img border="0" src="../img/lp_leftarrow.gif" title="' . get_lang('ScormPrevious') . '"></a>' . "\n" .
-            '        <a href="" onclick="switch_item(' . $mycurrentitemid . ',\'next\');return false;" title="next"  ><img border="0" src="../img/lp_rightarrow.gif" title="' . get_lang('ScormNext') . '"></a>' . "\n" .
+            '        <a href="lp_controller.php?action=stats" onClick="window.parent.API.save_asset();return true;" target="content_name" title="stats" id="stats_link"><img border="0" src="../img/lp_stats.gif" title="' . get_lang('Reporting') . '"></a>' . "\n" .
+            '        <a href="" onClick="switch_item(' . $mycurrentitemid . ',\'previous\');return false;" title="previous"><img border="0" src="../img/lp_leftarrow.gif" title="' . get_lang('ScormPrevious') . '"></a>' . "\n" .
+            '        <a href="" onClick="switch_item(' . $mycurrentitemid . ',\'next\');return false;" title="next"  ><img border="0" src="../img/lp_rightarrow.gif" title="' . get_lang('ScormNext') . '"></a>' . "\n" .
             // '        <a href="lp_controller.php?action=mode&mode=fullscreen" target="_top" title="fullscreen"><img border="0" src="../img/view_fullscreen.gif" width="18" height="18" title="'.get_lang('ScormFullScreen').'"></a>'."\n" .
             '      </div>' . "\n" .
             '    </td>' . "\n" .
@@ -2702,11 +2702,11 @@ class learnpath {
             if ($item['type'] != 'dokeos_chapter' && $item['type'] != 'dir' && $item['type'] != 'dokeos_module') {
                 //$html .= "<a href='lp_controller.php?".api_get_cidreq()."&action=content&lp_id=".$this->get_id()."&item_id=".$item['id']."' target='lp_content_frame_name'>".$title."</a>" ;
                 $url = $this->get_link('http', $item['id']);
-                //$html .= '<a href="'.$url.'" target="content_name" onclick="top.load_item('.$item['id'].',\''.$url.'\');">'.$title.'</a>' ;
-                //$html .= '<a href="" onclick="top.load_item('.$item['id'].',\''.$url.'\');return false;">'.$title.'</a>' ;
+                //$html .= '<a href="'.$url.'" target="content_name" onClick="top.load_item('.$item['id'].',\''.$url.'\');">'.$title.'</a>' ;
+                //$html .= '<a href="" onClick="top.load_item('.$item['id'].',\''.$url.'\');return false;">'.$title.'</a>' ;
 
                 //<img align="absbottom" width="13" height="13" src="../img/lp_document.png">&nbsp;background:#aaa;
-                $html .= '<a href="" onclick="switch_item(' .
+                $html .= '<a href="" onClick="switch_item(' .
                 $mycurrentitemid . ',' .
                 $item['id'] . ');' .
                 'return false;" >' . stripslashes($title) . '</a>';
@@ -4628,7 +4628,7 @@ class learnpath {
                     $return .= '</a>' . "\n";
                 }
 
-                $return .= "\t\t\t" . '<a href="' . api_get_self() . '?cidReq=' . Security :: remove_XSS($_GET['cidReq']) . '&amp;action=delete_item&amp;id=' . $arrLP[$i]['id'] . '&amp;lp_id=' . $this->lp_id . '" onclick="return confirmation(\'' . addslashes($title) . '\');">';
+                $return .= "\t\t\t" . '<a href="' . api_get_self() . '?cidReq=' . Security :: remove_XSS($_GET['cidReq']) . '&amp;action=delete_item&amp;id=' . $arrLP[$i]['id'] . '&amp;lp_id=' . $this->lp_id . '" onClick="return confirmation(\'' . addslashes($title) . '\');">';
                 $return .= '<img style="margin:1px;" alt="" src="../img/delete.gif" title="' . get_lang('_delete_learnpath_module') . '" />';
                 $return .= '</a>' . "\n";
 
@@ -5205,7 +5205,7 @@ class learnpath {
         $return .= "\t\t\t" . '<td class="label"><label for="idParent">' . get_lang('Parent') . '</label></td>' . "\n";
         $return .= "\t\t\t" . '<td class="input">' . "\n";
 
-        $return .= "\t\t\t\t" . '<select id="idParent" style="width:100%;" name="parent" onchange="javascript: load_cbo(this.value);" class="learnpath_item_form" size="1">';
+        $return .= "\t\t\t\t" . '<select id="idParent" style="width:100%;" name="parent" onChange="javascript: load_cbo(this.value);" class="learnpath_item_form" size="1">';
 
         $return .= "\t\t\t\t\t" . '<option class="top" value="0">' . $this->name . '</option>';
 
@@ -5430,7 +5430,7 @@ class learnpath {
         $return .= "\t\t" . '<tr>' . "\n";
         $return .= "\t\t\t" . '<td class="label"><label for="idParent">' . get_lang('Parent') . ' :</label></td>' . "\n";
         $return .= "\t\t\t" . '<td class="input">' . "\n";
-        $return .= "\t\t\t\t" . '<select id="idParent" name="parent" onchange="javascript: load_cbo(this.value);" size="1">';
+        $return .= "\t\t\t\t" . '<select id="idParent" name="parent" onChange="javascript: load_cbo(this.value);" size="1">';
         $return .= "\t\t\t\t\t" . '<option class="top" value="0">' . $this->name . '</option>';
         $arrHide = array (
             $id
@@ -5526,7 +5526,7 @@ class learnpath {
         }
 
         $return .= "\t\t" . '<tr>' . "\n";
-        $return .= "\t\t\t" . '<td> &nbsp;</td><td><button class="save" name="submit_button" action="edit" type="submit">' . get_lang('SaveHotpotatoes') . '</button></td>' . "\n";
+        $return .= "\t\t\t" . '<td>&nbsp; </td><td><button class="save" name="submit_button" action="edit" type="submit">' . get_lang('SaveHotpotatoes') . '</button></td>' . "\n";
         $return .= "\t\t" . '</tr>' . "\n";
         $return .= "\t" . '</table>' . "\n";
 
@@ -5646,7 +5646,7 @@ class learnpath {
         $return .= "\t\t" . '<tr>' . "\n";
         $return .= "\t\t\t" . '<td class="label"><label for="idParent">' . get_lang('Parent') . '</label></td>' . "\n";
         $return .= "\t\t\t" . '<td class="input">' . "\n";
-        $return .= "\t\t\t\t" . '<select id="idParent" style="width:100%;" name="parent" onchange="javascript: load_cbo(this.value);" class="learnpath_item_form" size="1">';
+        $return .= "\t\t\t\t" . '<select id="idParent" style="width:100%;" name="parent" onChange="javascript: load_cbo(this.value);" class="learnpath_item_form" size="1">';
         $return .= "\t\t\t\t\t" . '<option class="top" value="0">' . $this->name . '</option>';
         $arrHide = array (
             $id
@@ -5841,7 +5841,7 @@ class learnpath {
         $return .= "\t\t" . '<tr>' . "\n";
         $return .= "\t\t\t" . '<td class="label"><label for="idParent">' . get_lang('Parent') . '&nbsp;:</label></td>' . "\n";
         $return .= "\t\t\t" . '<td class="input">' . "\n";
-        $return .= "\t\t\t\t" . '<select id="idParent" name="parent" onchange="javascript: load_cbo(this.value);" size="1">';
+        $return .= "\t\t\t\t" . '<select id="idParent" name="parent" onChange="javascript: load_cbo(this.value);" size="1">';
         $return .= "\t\t\t\t\t" . '<option class="top" value="0">' . $this->name . '</option>';
         $arrHide = array (
             $id
@@ -6592,7 +6592,7 @@ class learnpath {
         $return .= "\t\t" . '<tr>' . "\n";
         $return .= "\t\t\t" . '<td class="label"><label for="idParent">' . get_lang('Parent') . '</label></td>' . "\n";
         $return .= "\t\t\t" . '<td class="input">' . "\n";
-        $return .= "\t\t\t\t" . '<select id="idParent" style="width:100%;" name="parent" onchange="javascript: load_cbo(this.value);" class="learnpath_item_form" size="1">';
+        $return .= "\t\t\t\t" . '<select id="idParent" style="width:100%;" name="parent" onChange="javascript: load_cbo(this.value);" class="learnpath_item_form" size="1">';
         $return .= "\t\t\t\t\t" . '<option class="top" value="0">' . $this->name . '</option>';
         $arrHide = array (
             $id
@@ -6807,7 +6807,7 @@ class learnpath {
         $return .= "\t\t" . '<tr>' . "\n";
         $return .= "\t\t\t" . '<td class="label"><label for="idParent">' . get_lang('Parent') . '</label></td>' . "\n";
         $return .= "\t\t\t" . '<td class="input">' . "\n";
-        $return .= "\t\t\t\t" . '<select id="idParent" name="parent" style="width:100%;" onchange="javascript: load_cbo(this.value);" class="learnpath_item_form" size="1">';
+        $return .= "\t\t\t\t" . '<select id="idParent" name="parent" style="width:100%;" onChange="javascript: load_cbo(this.value);" class="learnpath_item_form" size="1">';
         //$parent_item_id = $_SESSION['parent_item_id'];
         $return .= "\t\t\t\t\t" . '<option class="top" value="0">' . $this->name . '</option>';
         $arrHide = array (
@@ -7001,7 +7001,7 @@ class learnpath {
         if ($item_type != 'dokeos_chapter' && $item_type != 'chapter') {
             $return .= '<a href="' . api_get_self() . '?cidReq=' . Security :: remove_XSS($_GET['cidReq']) . '&amp;action=edit_item_prereq&amp;view=build&amp;id=' . $item_id . '&amp;lp_id=' . $this->lp_id . '" title="' . get_lang('Prerequisites') . '"><img align="absbottom" alt="' . get_lang('Prerequisites') . '" src="../img/right.gif" title="' . get_lang('Prerequisites') . '" /> ' . get_lang('Prerequisites') . '</a>';
         }
-        $return .= '<a href="' . api_get_self() . '?cidReq=' . Security :: remove_XSS($_GET['cidReq']) . '&amp;action=delete_item&amp;view=build&amp;id=' . $item_id . '&amp;lp_id=' . $this->lp_id . '" onclick="return confirmation(\'' . addslashes($s_title) . '\');" title="Delete the current item"><img alt="Delete the current item" align="absbottom" src="../img/delete.gif" title="' . get_lang('Delete') . '" /> ' . get_lang('Delete') . '</a>';
+        $return .= '<a href="' . api_get_self() . '?cidReq=' . Security :: remove_XSS($_GET['cidReq']) . '&amp;action=delete_item&amp;view=build&amp;id=' . $item_id . '&amp;lp_id=' . $this->lp_id . '" onClick="return confirmation(\'' . addslashes($s_title) . '\');" title="Delete the current item"><img alt="Delete the current item" align="absbottom" src="../img/delete.gif" title="' . get_lang('Delete') . '" /> ' . get_lang('Delete') . '</a>';
 
         //$return .= '<br /><br /><p class="lp_text">' . ((trim($s_description) == '') ? ''.get_lang('NoDescription').'' : stripslashes(nl2br($s_description))) . '</p>';
 
@@ -7430,8 +7430,36 @@ class learnpath {
         if (count($resources_sorted) > 0) {
             foreach ($resources_sorted as $key => $resource) {
                 if (is_int($resource['id'])) {
-                    // It's a folder.
-                    $return .= '<div><div style="margin-left:' . ($num * 15) . 'px;margin-right:5px;"><img style="cursor: pointer;" src="../img/nolines_plus.gif" align="absmiddle" id="img_' . $resource['id'] . '" onclick="javascript: testResources(\'' . $resource['id'] . '\',\'img_' . $resource['id'] . '\')"><img alt="" src="../img/lp_folder.gif" title="" align="absmiddle" />&nbsp;<span onclick="javascript: testResources(\'' . $resource['id'] . '\',\'img_' . $resource['id'] . '\')" style="cursor: pointer;" >' . $key . '</span></div><div style="display: none;" id="' . $resource['id'] . '">';
+                 // It's a folder.
+					//hide some folders
+					if (in_array($key, array('shared_folder','chat_files', 'HotPotatoes_files', 'css', 'certificates'))){
+						continue;
+					}elseif(preg_match('/_groupdocs/', $key)){
+						continue;
+					}elseif(preg_match('/sf_user_/', $key)){
+						continue;
+					}elseif(preg_match('/shared_folder_session_/', $key)){
+						continue;
+					}
+					
+					//trad some titles
+					if ($key=='images'){
+						$key=get_lang('Images');
+					}
+					elseif($key=='gallery'){
+						$key=get_lang('Gallery');
+					}
+					elseif($key=='flash'){
+						$key=get_lang('Flash');
+					}
+					elseif($key=='audio'){
+						$key=get_lang('Audio');
+					}					
+					elseif($key=='video'){
+						$key=get_lang('Video');
+					}
+					
+                    $return .= '<div><div style="margin-left:' . ($num * 15) . 'px;margin-right:5px;"><img style="cursor: pointer;" src="../img/nolines_plus.gif" align="absmiddle" id="img_' . $resource['id'] . '" onClick="javascript: testResources(\'' . $resource['id'] . '\',\'img_' . $resource['id'] . '\')"><img alt="" src="../img/lp_folder.gif" title="" align="absmiddle" />&nbsp;<span onClick="javascript: testResources(\'' . $resource['id'] . '\',\'img_' . $resource['id'] . '\')" style="cursor: pointer;" >' . $key . '</span></div><div style="display: none;" id="' . $resource['id'] . '">';
                     $return .= $this->write_resources_tree($resource['files'], $num +1);
                     $return .= '</div></div>';
                 } else {

+ 1 - 1
main/wiki/index.php

@@ -117,7 +117,7 @@ if ($_SESSION['_gid'] OR $_GET['group_id']) {
 }
 
 
-if ($_POST['action']=='export_to_pdf' && isset($_POST['wiki_id']) ) {    
+if ($_POST['action']=='export_to_pdf' && isset($_POST['wiki_id']) && api_get_setting('students_export2pdf') == 'true') {    
     export_to_pdf($_POST['wiki_id'], api_get_course_id());    
 }