@@ -18,14 +18,8 @@ |
||
18 | 18 | use Facebook\FacebookSession; |
19 | 19 | use Facebook\FacebookRedirectLoginHelper; |
20 | 20 | use Facebook\FacebookRequest; |
21 | -use Facebook\FacebookResponse; |
|
22 | 21 | use Facebook\FacebookSDKException; |
23 | 22 | use Facebook\FacebookRequestException; |
24 | -use Facebook\FacebookAuthorizationException; |
|
25 | -use Facebook\GraphObject; |
|
26 | -use Facebook\Entities\AccessToken; |
|
27 | -use Facebook\HttpClients\FacebookCurlHttpClient; |
|
28 | -use Facebook\HttpClients\FacebookHttpable; |
|
29 | 23 | |
30 | 24 | require_once dirname(__FILE__) . '/functions.inc.php'; |
31 | 25 |
@@ -1,8 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | /* For licensing terms, see /license.txt */ |
3 | 3 | |
4 | -use ChamiloSession as Session; |
|
5 | - |
|
6 | 4 | /** |
7 | 5 | * Class ExerciseLib |
8 | 6 | * shows a question and its answers |
@@ -3,14 +3,8 @@ |
||
3 | 3 | |
4 | 4 | use Ddeboer\DataImport\Writer\ExcelWriter; |
5 | 5 | use Ddeboer\DataImport\Writer\CsvWriter; |
6 | -use Ddeboer\DataImport\Workflow; |
|
7 | - |
|
8 | -use Ddeboer\DataImport\Reader\CsvReader; |
|
9 | -use Ddeboer\DataImport\Reader\ArrayReader; |
|
10 | -use Ddeboer\DataImport\Writer\ArrayWriter; |
|
11 | 6 | use Chamilo\CoreBundle\Component\Editor\Connector; |
12 | 7 | use Chamilo\CoreBundle\Component\Filesystem\Data; |
13 | -use ChamiloSession as Session; |
|
14 | 8 | use MediaAlchemyst\Alchemyst; |
15 | 9 | use MediaAlchemyst\DriversContainer; |
16 | 10 | use Neutron\TemporaryFilesystem\Manager; |
@@ -56,7 +56,7 @@ discard block |
||
56 | 56 | |
57 | 57 | DocumentManager::file_send_for_download($filePath, true, $filename.'.csv'); |
58 | 58 | exit; |
59 | - } |
|
59 | + } |
|
60 | 60 | |
61 | 61 | /** |
62 | 62 | * Export tabular data to XLS-file |
@@ -79,7 +79,7 @@ discard block |
||
79 | 79 | |
80 | 80 | DocumentManager::file_send_for_download($filePath, true, $filename.'.xlsx'); |
81 | 81 | exit; |
82 | - } |
|
82 | + } |
|
83 | 83 | |
84 | 84 | /** |
85 | 85 | * Export tabular data to XLS-file (as html table) |
@@ -112,13 +112,13 @@ discard block |
||
112 | 112 | } |
113 | 113 | |
114 | 114 | /** |
115 | - * Export tabular data to XML-file |
|
116 | - * @param array Simple array of data to put in XML |
|
117 | - * @param string Name of file to be given to the user |
|
118 | - * @param string Name of common tag to place each line in |
|
119 | - * @param string Name of the root element. A root element should always be given. |
|
120 | - * @param string Encoding in which the data is provided |
|
121 | - */ |
|
115 | + * Export tabular data to XML-file |
|
116 | + * @param array Simple array of data to put in XML |
|
117 | + * @param string Name of file to be given to the user |
|
118 | + * @param string Name of common tag to place each line in |
|
119 | + * @param string Name of the root element. A root element should always be given. |
|
120 | + * @param string Encoding in which the data is provided |
|
121 | + */ |
|
122 | 122 | public static function arrayToXml( |
123 | 123 | $data, |
124 | 124 | $filename = 'export', |
@@ -148,7 +148,7 @@ discard block |
||
148 | 148 | fclose($handle); |
149 | 149 | DocumentManager :: file_send_for_download($file, true, $filename.'.xml'); |
150 | 150 | exit; |
151 | - } |
|
151 | + } |
|
152 | 152 | |
153 | 153 | /** |
154 | 154 | * Export hierarchical tabular data to XML-file |
@@ -197,7 +197,7 @@ discard block |
||
197 | 197 | foreach ($data as $row) { |
198 | 198 | $string .= "\n".str_repeat("\t",$level).'<'.$row['name'].'>'; |
199 | 199 | if (is_array($row['value'])) { |
200 | - $string .= self::_export_complex_table_xml_helper($row['value'],$level+1)."\n"; |
|
200 | + $string .= self::_export_complex_table_xml_helper($row['value'],$level+1)."\n"; |
|
201 | 201 | $string .= str_repeat("\t",$level).'</'.$row['name'].'>'; |
202 | 202 | } else { |
203 | 203 | $string .= $row['value']; |
@@ -2,7 +2,6 @@ |
||
2 | 2 | /* For licensing terms, see /license.txt */ |
3 | 3 | |
4 | 4 | use ChamiloSession as Session; |
5 | - |
|
6 | 5 | use Chamilo\UserBundle\Entity\User; |
7 | 6 | |
8 | 7 | /** |
@@ -838,18 +838,18 @@ |
||
838 | 838 | $email = false; |
839 | 839 | } |
840 | 840 | |
841 | - if ($email) { |
|
842 | - $condition = "LOWER(email) = '".Database::escape_string($username)."' "; |
|
843 | - } else { |
|
841 | + if ($email) { |
|
842 | + $condition = "LOWER(email) = '".Database::escape_string($username)."' "; |
|
843 | + } else { |
|
844 | 844 | $condition = "LOWER(username) = '".Database::escape_string($username)."'"; |
845 | 845 | } |
846 | 846 | |
847 | - $tbl_user = Database :: get_main_table(TABLE_MAIN_USER); |
|
848 | - $query = "SELECT user_id AS uid, lastname AS lastName, firstname AS firstName, username AS loginName, password, email, |
|
847 | + $tbl_user = Database :: get_main_table(TABLE_MAIN_USER); |
|
848 | + $query = "SELECT user_id AS uid, lastname AS lastName, firstname AS firstName, username AS loginName, password, email, |
|
849 | 849 | status AS status, official_code, phone, picture_uri, creator_id |
850 | 850 | FROM $tbl_user |
851 | 851 | WHERE ( $condition AND active = 1) "; |
852 | - $result = Database::query($query); |
|
852 | + $result = Database::query($query); |
|
853 | 853 | $num_rows = Database::num_rows($result); |
854 | 854 | if ($result && $num_rows > 0) { |
855 | 855 | return Database::fetch_assoc($result); |
@@ -1,9 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | /* For licensing terms, see /license.txt */ |
3 | 3 | |
4 | -use Chamilo\CoreBundle\Entity\ExtraField as EntityExtraField; |
|
5 | -use Chamilo\UserBundle\Entity\User; |
|
6 | - |
|
7 | 4 | /** |
8 | 5 | * @package chamilo.webservices |
9 | 6 | */ |
@@ -1,14 +1,8 @@ |
||
1 | 1 | <?php |
2 | 2 | /* For licensing terms, see /license.txt */ |
3 | 3 | |
4 | -use Chamilo\CoreBundle\Component\Editor\Connector; |
|
5 | 4 | use Chamilo\CoreBundle\Component\Filesystem\Data; |
6 | 5 | use ChamiloSession as Session; |
7 | -use MediaAlchemyst\Alchemyst; |
|
8 | -use MediaAlchemyst\DriversContainer; |
|
9 | -use Neutron\TemporaryFilesystem\Manager; |
|
10 | -use Neutron\TemporaryFilesystem\TemporaryFilesystem; |
|
11 | -use Symfony\Component\Filesystem\Filesystem; |
|
12 | 6 | |
13 | 7 | /** |
14 | 8 | * Class Wiki |
@@ -1,7 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | /* For licensing terms, see /license.txt */ |
3 | 3 | |
4 | -use ChamiloSession as Session; |
|
5 | 4 | use Symfony\Component\Finder\Finder; |
6 | 5 | |
7 | 6 | require_once '../inc/global.inc.php'; |
@@ -8,7 +8,6 @@ |
||
8 | 8 | use Chamilo\UserBundle\Entity\User; |
9 | 9 | use MediaAlchemyst\Alchemyst; |
10 | 10 | use Sunra\PhpSimple\HtmlDomParser; |
11 | -use Symfony\Component\Console; |
|
12 | 11 | use Symfony\Component\Console\Output\OutputInterface; |
13 | 12 | use Symfony\Component\Filesystem\Filesystem; |
14 | 13 | use Symfony\Component\Finder\Finder; |
@@ -86,13 +86,13 @@ |
||
86 | 86 | return $this->get($file); |
87 | 87 | } |
88 | 88 | |
89 | - /** |
|
90 | - * Gets a file from the data/courses/MATHS/scorm directory |
|
91 | - * @param string $courseCode |
|
92 | - * @param string $file |
|
93 | - * |
|
94 | - * @return SplFileInfo |
|
95 | - */ |
|
89 | + /** |
|
90 | + * Gets a file from the data/courses/MATHS/scorm directory |
|
91 | + * @param string $courseCode |
|
92 | + * @param string $file |
|
93 | + * |
|
94 | + * @return SplFileInfo |
|
95 | + */ |
|
96 | 96 | public function getCourseScormDocument($courseCode, $file) |
97 | 97 | { |
98 | 98 | $file = 'courses/'.$courseCode.'/scorm/'.$file; |
@@ -3,11 +3,9 @@ |
||
3 | 3 | |
4 | 4 | namespace Chamilo\CoreBundle\Entity\Listener; |
5 | 5 | |
6 | -use Chamilo\CoreBundle\Entity\Tool; |
|
7 | 6 | use Chamilo\CourseBundle\ToolChain; |
8 | 7 | use Doctrine\ORM\Event\LifecycleEventArgs; |
9 | 8 | use Chamilo\CoreBundle\Entity\Course; |
10 | -use Doctrine\ORM\Mapping as ORM; |
|
11 | 9 | |
12 | 10 | /** |
13 | 11 | * Class CourseListener |