@@ -29,13 +29,13 @@ |
||
29 | 29 | function pix_url($pixname, $size = 16) { |
30 | 30 | global $_configuration; |
31 | 31 | |
32 | - if (file_exists($_configuration['root_sys'].'/plugin/customplugin/pix/'.$pixname.'.png')){ |
|
32 | + if (file_exists($_configuration['root_sys'].'/plugin/customplugin/pix/'.$pixname.'.png')) { |
|
33 | 33 | return $_configuration['root_web'].'/plugin/customplugin/pix/'.$pixname.'.png'; |
34 | 34 | } |
35 | - if (file_exists($_configuration['root_sys'].'/plugin/customplugin/pix/'.$pixname.'.jpg')){ |
|
35 | + if (file_exists($_configuration['root_sys'].'/plugin/customplugin/pix/'.$pixname.'.jpg')) { |
|
36 | 36 | return $_configuration['root_web'].'/plugin/customplugin/pix/'.$pixname.'.jpg'; |
37 | 37 | } |
38 | - if (file_exists($_configuration['root_sys'].'/plugin/customplugin/pix/'.$pixname.'.gif')){ |
|
38 | + if (file_exists($_configuration['root_sys'].'/plugin/customplugin/pix/'.$pixname.'.gif')) { |
|
39 | 39 | return $_configuration['root_web'].'/plugin/customplugin/pix/'.$pixname.'.gif'; |
40 | 40 | } |
41 | 41 | return $_configuration['root_web'].'/main/img/icons/'.$size.'/'.$pixname.'.png'; |
@@ -9,7 +9,7 @@ discard block |
||
9 | 9 | require_once '../inc/lib/baker.lib.php'; |
10 | 10 | |
11 | 11 | if (!isset($_REQUEST['user'], $_REQUEST['issue'])) { |
12 | - header('Location: ' . api_get_path(WEB_PATH)); |
|
12 | + header('Location: '.api_get_path(WEB_PATH)); |
|
13 | 13 | exit; |
14 | 14 | } |
15 | 15 | |
@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | Display::return_message(get_lang('NoResults'), 'error') |
25 | 25 | ); |
26 | 26 | |
27 | - header('Location: ' . api_get_path(WEB_PATH)); |
|
27 | + header('Location: '.api_get_path(WEB_PATH)); |
|
28 | 28 | exit; |
29 | 29 | } |
30 | 30 | |
@@ -33,7 +33,7 @@ discard block |
||
33 | 33 | Display::return_message(get_lang('NoResults'), 'error') |
34 | 34 | ); |
35 | 35 | |
36 | - header('Location: ' . api_get_path(WEB_PATH)); |
|
36 | + header('Location: '.api_get_path(WEB_PATH)); |
|
37 | 37 | exit; |
38 | 38 | } |
39 | 39 | |
@@ -144,7 +144,7 @@ discard block |
||
144 | 144 | $entityManager->persist($skillIssue); |
145 | 145 | $entityManager->flush(); |
146 | 146 | |
147 | - header("Location: " . $skillIssue->getIssueUrl()); |
|
147 | + header("Location: ".$skillIssue->getIssueUrl()); |
|
148 | 148 | exit; |
149 | 149 | } |
150 | 150 | |
@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | $entityManager->persist($skillUserComment); |
176 | 176 | $entityManager->flush(); |
177 | 177 | |
178 | - header("Location: " . $skillIssue->getIssueUrl()); |
|
178 | + header("Location: ".$skillIssue->getIssueUrl()); |
|
179 | 179 | exit; |
180 | 180 | } |
181 | 181 | |
@@ -191,11 +191,11 @@ discard block |
||
191 | 191 | $backpack = $configBackpack; |
192 | 192 | } |
193 | 193 | |
194 | - $htmlHeadXtra[] = '<script src="' . $backpack . 'issuer.js"></script>'; |
|
194 | + $htmlHeadXtra[] = '<script src="'.$backpack.'issuer.js"></script>'; |
|
195 | 195 | $objSkill = new Skill(); |
196 | 196 | $assertionUrl = $skillIssueInfo['badge_asserion'][0]; |
197 | 197 | $skills = $objSkill->get($skillId); |
198 | - $unbakedBadge = api_get_path(SYS_UPLOAD_PATH) . "badges/".$skills['icon']; |
|
198 | + $unbakedBadge = api_get_path(SYS_UPLOAD_PATH)."badges/".$skills['icon']; |
|
199 | 199 | |
200 | 200 | $unbakedBadge = file_get_contents($unbakedBadge); |
201 | 201 | $badgeInfoError = false; |
@@ -210,12 +210,12 @@ discard block |
||
210 | 210 | mkdir($bakedBadge, api_get_permissions_for_new_directories(), true); |
211 | 211 | } |
212 | 212 | $skillRelUserId = $skillIssueInfo['id']; |
213 | - if (!file_exists($bakedBadge . "/badge_" . $skillRelUserId)) { |
|
214 | - file_put_contents($bakedBadge . "/badge_" . $skillRelUserId . ".png", $bakedInfo); |
|
213 | + if (!file_exists($bakedBadge."/badge_".$skillRelUserId)) { |
|
214 | + file_put_contents($bakedBadge."/badge_".$skillRelUserId.".png", $bakedInfo); |
|
215 | 215 | } |
216 | 216 | |
217 | 217 | //Process to validate a baked badge |
218 | - $badgeContent = file_get_contents($bakedBadge . "/badge_" . $skillRelUserId . ".png"); |
|
218 | + $badgeContent = file_get_contents($bakedBadge."/badge_".$skillRelUserId.".png"); |
|
219 | 219 | $verifyBakedBadge = $png->extractBadgeInfo($badgeContent); |
220 | 220 | if (!is_array($verifyBakedBadge)) { |
221 | 221 | $badgeInfoError = true; |
@@ -223,7 +223,7 @@ discard block |
||
223 | 223 | |
224 | 224 | if (!$badgeInfoError) { |
225 | 225 | $personalBadge = UserManager::getUserPathById($userId, "web"); |
226 | - $personalBadge = $personalBadge."badges/badge_" . $skillRelUserId . ".png"; |
|
226 | + $personalBadge = $personalBadge."badges/badge_".$skillRelUserId.".png"; |
|
227 | 227 | } |
228 | 228 | } |
229 | 229 | } |
@@ -16,7 +16,7 @@ discard block |
||
16 | 16 | |
17 | 17 | $listAction = api_get_self(); |
18 | 18 | |
19 | -$action = ''; |
|
19 | +$action = ''; |
|
20 | 20 | if (isset($_GET['action']) && in_array($_GET['action'], ['add', 'edit', 'delete', 'add_level'])) { |
21 | 21 | $action = $_GET['action']; |
22 | 22 | } |
@@ -49,8 +49,8 @@ discard block |
||
49 | 49 | } |
50 | 50 | $formToDisplay = $form->returnForm(); |
51 | 51 | |
52 | -$interbreadcrumb[] = array ('url' => 'index.php', 'name' => get_lang('PlatformAdmin')); |
|
53 | -$interbreadcrumb[] = array ('url' => api_get_self(), 'name' => get_lang('SkillProfile')); |
|
52 | +$interbreadcrumb[] = array('url' => 'index.php', 'name' => get_lang('PlatformAdmin')); |
|
53 | +$interbreadcrumb[] = array('url' => api_get_self(), 'name' => get_lang('SkillProfile')); |
|
54 | 54 | |
55 | 55 | $tpl = new Template($action); |
56 | 56 | switch ($action) { |
@@ -5,10 +5,10 @@ |
||
5 | 5 | * @author Angel Fernando Quiroz Campos <[email protected]> |
6 | 6 | * @package chamilo.plugin.tour |
7 | 7 | */ |
8 | -require_once __DIR__ . '/config.php'; |
|
8 | +require_once __DIR__.'/config.php'; |
|
9 | 9 | |
10 | -$pluginPath = api_get_path(SYS_PLUGIN_PATH) . 'tour/'; |
|
11 | -$pluginWebPath = api_get_path(WEB_PLUGIN_PATH) . 'tour/'; |
|
10 | +$pluginPath = api_get_path(SYS_PLUGIN_PATH).'tour/'; |
|
11 | +$pluginWebPath = api_get_path(WEB_PLUGIN_PATH).'tour/'; |
|
12 | 12 | |
13 | 13 | $userId = api_get_user_id(); |
14 | 14 |
@@ -129,8 +129,8 @@ |
||
129 | 129 | */ |
130 | 130 | public function getTourConfig() |
131 | 131 | { |
132 | - $pluginPath = api_get_path(SYS_PLUGIN_PATH) . 'tour/'; |
|
133 | - $jsonContent = file_get_contents($pluginPath . 'config/tour.json'); |
|
132 | + $pluginPath = api_get_path(SYS_PLUGIN_PATH).'tour/'; |
|
133 | + $jsonContent = file_get_contents($pluginPath.'config/tour.json'); |
|
134 | 134 | $jsonData = json_decode($jsonContent, true); |
135 | 135 | |
136 | 136 | return $jsonData; |
@@ -9,7 +9,7 @@ |
||
9 | 9 | |
10 | 10 | define('TABLE_TOUR_LOG', 'plugin_tour_log'); |
11 | 11 | |
12 | -require_once api_get_path(SYS_PATH) . 'main/inc/global.inc.php'; |
|
13 | -require_once api_get_path(LIBRARY_PATH) . 'plugin.class.php'; |
|
14 | -require_once api_get_path(SYS_PLUGIN_PATH) . 'tour/src/tour_plugin.class.php'; |
|
12 | +require_once api_get_path(SYS_PATH).'main/inc/global.inc.php'; |
|
13 | +require_once api_get_path(LIBRARY_PATH).'plugin.class.php'; |
|
14 | +require_once api_get_path(SYS_PLUGIN_PATH).'tour/src/tour_plugin.class.php'; |
|
15 | 15 | // Edit the config/tour.json file to add more pages or more elements to the guide |
@@ -6,8 +6,8 @@ |
||
6 | 6 | * @package chamilo.plugin.tour |
7 | 7 | */ |
8 | 8 | require_once __DIR__.'/../../../main/inc/global.inc.php'; |
9 | -require_once api_get_path(LIBRARY_PATH) . 'plugin.class.php'; |
|
10 | -require_once api_get_path(SYS_PLUGIN_PATH) . 'tour/src/tour_plugin.class.php'; |
|
9 | +require_once api_get_path(LIBRARY_PATH).'plugin.class.php'; |
|
10 | +require_once api_get_path(SYS_PLUGIN_PATH).'tour/src/tour_plugin.class.php'; |
|
11 | 11 | |
12 | 12 | if (!api_is_anonymous()) { |
13 | 13 | $currentPageClass = isset($_GET['page_class']) ? $_GET['page_class'] : ''; |
@@ -33,26 +33,26 @@ discard block |
||
33 | 33 | $my_cur_dir_path = isset($_GET['curdirpath']) ? Security::remove_XSS($_GET['curdirpath']) : null; |
34 | 34 | } |
35 | 35 | |
36 | -$dir= str_replace('\\', '/', $dir);//and urlencode each url $curdirpath (hack clean $curdirpath under Windows - Bug #3261) |
|
36 | +$dir = str_replace('\\', '/', $dir); //and urlencode each url $curdirpath (hack clean $curdirpath under Windows - Bug #3261) |
|
37 | 37 | |
38 | 38 | /* Constants & Variables */ |
39 | -$current_session_id=api_get_session_id(); |
|
39 | +$current_session_id = api_get_session_id(); |
|
40 | 40 | //path for pixlr save |
41 | -$_SESSION['paint_dir']=Security::remove_XSS($dir); |
|
42 | -if($_SESSION['paint_dir']=='/'){ |
|
43 | - $_SESSION['paint_dir']=''; |
|
41 | +$_SESSION['paint_dir'] = Security::remove_XSS($dir); |
|
42 | +if ($_SESSION['paint_dir'] == '/') { |
|
43 | + $_SESSION['paint_dir'] = ''; |
|
44 | 44 | } |
45 | -$_SESSION['paint_file']=basename(Security::remove_XSS($file_path)); |
|
45 | +$_SESSION['paint_file'] = basename(Security::remove_XSS($file_path)); |
|
46 | 46 | |
47 | 47 | $get_file = Security::remove_XSS($file_path); |
48 | 48 | |
49 | 49 | $file = basename($get_file); |
50 | 50 | |
51 | -$temp_file = explode(".",$file); |
|
52 | -$filename=$temp_file[0]; |
|
53 | -$nameTools = get_lang('EditDocument') . ': '.$filename; |
|
51 | +$temp_file = explode(".", $file); |
|
52 | +$filename = $temp_file[0]; |
|
53 | +$nameTools = get_lang('EditDocument').': '.$filename; |
|
54 | 54 | |
55 | -$courseDir = $_course['path'].'/document'; |
|
55 | +$courseDir = $_course['path'].'/document'; |
|
56 | 56 | |
57 | 57 | $is_allowed_to_edit = api_is_allowed_to_edit(null, true); |
58 | 58 | |
@@ -96,15 +96,15 @@ discard block |
||
96 | 96 | $is_certificate_mode = DocumentManager::is_certificate_mode($dir); |
97 | 97 | |
98 | 98 | if (!$is_certificate_mode) |
99 | - $interbreadcrumb[]= array("url" => "./document.php?curdirpath=".urlencode($my_cur_dir_path).'&'.api_get_cidreq(), "name"=> get_lang('Documents')); |
|
99 | + $interbreadcrumb[] = array("url" => "./document.php?curdirpath=".urlencode($my_cur_dir_path).'&'.api_get_cidreq(), "name"=> get_lang('Documents')); |
|
100 | 100 | else |
101 | - $interbreadcrumb[]= array ('url' => '../gradebook/'.$_SESSION['gradebook_dest'], 'name' => get_lang('Gradebook')); |
|
101 | + $interbreadcrumb[] = array('url' => '../gradebook/'.$_SESSION['gradebook_dest'], 'name' => get_lang('Gradebook')); |
|
102 | 102 | |
103 | 103 | // Interbreadcrumb for the current directory root path |
104 | 104 | if (empty($document_data['parents'])) { |
105 | 105 | $interbreadcrumb[] = array('url' => '#', 'name' => $document_data['title']); |
106 | 106 | } else { |
107 | - foreach($document_data['parents'] as $document_sub_data) { |
|
107 | + foreach ($document_data['parents'] as $document_sub_data) { |
|
108 | 108 | if ($document_data['title'] == $document_sub_data['title']) { |
109 | 109 | continue; |
110 | 110 | } |
@@ -124,33 +124,33 @@ discard block |
||
124 | 124 | Display :: display_header($nameTools, 'Doc'); |
125 | 125 | echo '<div class="actions">'; |
126 | 126 | echo '<a href="document.php?id='.$parent_id.'&'.api_get_cidreq().'">'. |
127 | - Display::return_icon('back.png',get_lang('BackTo').' '.get_lang('DocumentsOverview'),'',ICON_SIZE_MEDIUM).'</a>'; |
|
127 | + Display::return_icon('back.png', get_lang('BackTo').' '.get_lang('DocumentsOverview'), '', ICON_SIZE_MEDIUM).'</a>'; |
|
128 | 128 | echo '<a href="edit_document.php?'.api_get_cidreq().'&id='.$document_id.'&'.api_get_cidreq().'&origin=editpaint">'. |
129 | - Display::return_icon('edit.png', get_lang('Rename').'/'.get_lang('Comment'),'',ICON_SIZE_MEDIUM).'</a>'; |
|
129 | + Display::return_icon('edit.png', get_lang('Rename').'/'.get_lang('Comment'), '', ICON_SIZE_MEDIUM).'</a>'; |
|
130 | 130 | echo '</div>'; |
131 | 131 | |
132 | 132 | ///pixlr |
133 | -$title=$file;//disk name. No sql name because pixlr return this when save |
|
133 | +$title = $file; //disk name. No sql name because pixlr return this when save |
|
134 | 134 | $pixlr_code_translation_table = array('' => 'en', 'pt' => 'pt-Pt', 'sr' => 'sr_latn'); |
135 | -$langpixlr = api_get_language_isocode(); |
|
135 | +$langpixlr = api_get_language_isocode(); |
|
136 | 136 | $langpixlr = isset($pixlr_code_translation_table[$langpixlr]) ? $pixlredit_code_translation_table[$langpixlr] : $langpixlr; |
137 | -$loc=$langpixlr;// deprecated ?? TODO:check pixlr read user browser |
|
137 | +$loc = $langpixlr; // deprecated ?? TODO:check pixlr read user browser |
|
138 | 138 | |
139 | -$exit_path=api_get_path(WEB_CODE_PATH).'document/exit_pixlr.php'; |
|
140 | -$_SESSION['exit_pixlr']= Security::remove_XSS($parent_id); |
|
139 | +$exit_path = api_get_path(WEB_CODE_PATH).'document/exit_pixlr.php'; |
|
140 | +$_SESSION['exit_pixlr'] = Security::remove_XSS($parent_id); |
|
141 | 141 | |
142 | -$referrer="Chamilo"; |
|
142 | +$referrer = "Chamilo"; |
|
143 | 143 | |
144 | -$target_path=api_get_path(WEB_CODE_PATH).'document/save_pixlr.php'; |
|
145 | -$target=$target_path; |
|
144 | +$target_path = api_get_path(WEB_CODE_PATH).'document/save_pixlr.php'; |
|
145 | +$target = $target_path; |
|
146 | 146 | |
147 | -$locktarget="true"; |
|
148 | -$locktitle="false"; |
|
147 | +$locktarget = "true"; |
|
148 | +$locktitle = "false"; |
|
149 | 149 | |
150 | -if ($_SERVER['HTTP_HOST']=="localhost") { |
|
151 | - $path_and_file= api_get_path(SYS_PATH).'/crossdomain.xml'; |
|
150 | +if ($_SERVER['HTTP_HOST'] == "localhost") { |
|
151 | + $path_and_file = api_get_path(SYS_PATH).'/crossdomain.xml'; |
|
152 | 152 | if (!file_exists($path_and_file)) { |
153 | - $crossdomain='<?xml version="1.0"?> |
|
153 | + $crossdomain = '<?xml version="1.0"?> |
|
154 | 154 | <!DOCTYPE cross-domain-policy SYSTEM "http://www.adobe.com/xml/dtds/cross-domain-policy.dtd"> |
155 | 155 | <cross-domain-policy> |
156 | 156 | <allow-access-from domain="cdn.pixlr.com" /> |
@@ -159,23 +159,23 @@ discard block |
||
159 | 159 | </cross-domain-policy>';//more open domain="*" |
160 | 160 | @file_put_contents($path_and_file, $crossdomain); |
161 | 161 | } |
162 | - $credentials="true"; |
|
162 | + $credentials = "true"; |
|
163 | 163 | } |
164 | 164 | else { |
165 | - $credentials="false"; |
|
165 | + $credentials = "false"; |
|
166 | 166 | } |
167 | 167 | |
168 | 168 | //make temp images |
169 | -$temp_folder=api_get_path(SYS_ARCHIVE_PATH).'temp/images'; |
|
169 | +$temp_folder = api_get_path(SYS_ARCHIVE_PATH).'temp/images'; |
|
170 | 170 | if (!file_exists($temp_folder)) { |
171 | - @mkdir($temp_folder, api_get_permissions_for_new_directories(), true);//TODO:check $permissions value, now empty; |
|
171 | + @mkdir($temp_folder, api_get_permissions_for_new_directories(), true); //TODO:check $permissions value, now empty; |
|
172 | 172 | } |
173 | 173 | |
174 | 174 | //make htaccess with allow from all, and file index.html into temp/images |
175 | -$htaccess=api_get_path(SYS_ARCHIVE_PATH).'temp/images/.htaccess'; |
|
175 | +$htaccess = api_get_path(SYS_ARCHIVE_PATH).'temp/images/.htaccess'; |
|
176 | 176 | if (!file_exists($htaccess)) { |
177 | 177 | |
178 | - $htaccess_content="order deny,allow\r\nallow from all\r\nOptions -Indexes"; |
|
178 | + $htaccess_content = "order deny,allow\r\nallow from all\r\nOptions -Indexes"; |
|
179 | 179 | |
180 | 180 | $fp = @ fopen(api_get_path(SYS_ARCHIVE_PATH).'temp/images/.htaccess', 'w'); |
181 | 181 | if ($fp) { |
@@ -184,9 +184,9 @@ discard block |
||
184 | 184 | } |
185 | 185 | } |
186 | 186 | |
187 | -$html_index=api_get_path(SYS_ARCHIVE_PATH).'temp/images/index.html'; |
|
187 | +$html_index = api_get_path(SYS_ARCHIVE_PATH).'temp/images/index.html'; |
|
188 | 188 | if (!file_exists($html_index)) { |
189 | - $html_index_content="<html><head></head><body></body></html>"; |
|
189 | + $html_index_content = "<html><head></head><body></body></html>"; |
|
190 | 190 | $fp = @ fopen(api_get_path(SYS_ARCHIVE_PATH).'temp/images/index.html', 'w'); |
191 | 191 | if ($fp) { |
192 | 192 | fwrite($fp, $html_index_content); |
@@ -195,20 +195,20 @@ discard block |
||
195 | 195 | } |
196 | 196 | |
197 | 197 | //encript temp name file |
198 | -$name_crip=sha1(uniqid());//encript |
|
199 | -$findext= explode(".", $file); |
|
200 | -$extension= $findext[count($findext)-1]; |
|
201 | -$file_crip=$name_crip.'.'.$extension; |
|
198 | +$name_crip = sha1(uniqid()); //encript |
|
199 | +$findext = explode(".", $file); |
|
200 | +$extension = $findext[count($findext) - 1]; |
|
201 | +$file_crip = $name_crip.'.'.$extension; |
|
202 | 202 | |
203 | 203 | //copy file to temp/images directory |
204 | -$from=$filepath.$file; |
|
205 | -$to=api_get_path(SYS_ARCHIVE_PATH).'temp/images/'.$file_crip; |
|
204 | +$from = $filepath.$file; |
|
205 | +$to = api_get_path(SYS_ARCHIVE_PATH).'temp/images/'.$file_crip; |
|
206 | 206 | copy($from, $to); |
207 | -$_SESSION['temp_realpath_image']=$to; |
|
207 | +$_SESSION['temp_realpath_image'] = $to; |
|
208 | 208 | |
209 | 209 | //load image to url |
210 | -$to_url=api_get_path(WEB_ARCHIVE_PATH).'temp/images/'.$file_crip; |
|
211 | -$image=urlencode($to_url); |
|
210 | +$to_url = api_get_path(WEB_ARCHIVE_PATH).'temp/images/'.$file_crip; |
|
211 | +$image = urlencode($to_url); |
|
212 | 212 | $pixlr_url = api_get_protocol().'://pixlr.com/editor/?title='.$title.'&image='.$image.'&loc='.$loc.'&referrer='.$referrer.'&target='.$target.'&exit='.$exit_path.'&locktarget='.$locktarget.'&locktitle='.$locktitle.'&credentials='.$credentials; |
213 | 213 | |
214 | 214 | //make frame an send image |
@@ -129,27 +129,27 @@ |
||
129 | 129 | |
130 | 130 | // pixlr |
131 | 131 | // max size 1 Mb ?? |
132 | -$title = urlencode(utf8_encode(get_lang('NewImage')));//TODO:check |
|
132 | +$title = urlencode(utf8_encode(get_lang('NewImage'))); //TODO:check |
|
133 | 133 | // |
134 | 134 | $image = Display::returnIconPath('canvas1024x768.png'); |
135 | 135 | // |
136 | 136 | $pixlr_code_translation_table = array('' => 'en', 'pt' => 'pt-Pt', 'sr' => 'sr_latn'); |
137 | -$langpixlr = api_get_language_isocode(); |
|
137 | +$langpixlr = api_get_language_isocode(); |
|
138 | 138 | $langpixlr = isset($pixlr_code_translation_table[$langpixlr]) ? $pixlredit_code_translation_table[$langpixlr] : $langpixlr; |
139 | -$loc=$langpixlr;// deprecated ?? TODO:check pixlr read user browser |
|
140 | - |
|
141 | -$exit_path=api_get_path(WEB_CODE_PATH).'document/exit_pixlr.php'; |
|
142 | -$_SESSION['exit_pixlr']=$document_data['path']; |
|
143 | -$referrer="Chamilo"; |
|
144 | -$target_path=api_get_path(WEB_CODE_PATH).'document/save_pixlr.php'; |
|
145 | -$target=$target_path; |
|
146 | -$locktarget="true"; |
|
147 | -$locktitle="false"; |
|
148 | - |
|
149 | -if ($_SERVER['HTTP_HOST']=="localhost") { |
|
150 | - $path_and_file= api_get_path(SYS_PATH).'/crossdomain.xml'; |
|
139 | +$loc = $langpixlr; // deprecated ?? TODO:check pixlr read user browser |
|
140 | + |
|
141 | +$exit_path = api_get_path(WEB_CODE_PATH).'document/exit_pixlr.php'; |
|
142 | +$_SESSION['exit_pixlr'] = $document_data['path']; |
|
143 | +$referrer = "Chamilo"; |
|
144 | +$target_path = api_get_path(WEB_CODE_PATH).'document/save_pixlr.php'; |
|
145 | +$target = $target_path; |
|
146 | +$locktarget = "true"; |
|
147 | +$locktitle = "false"; |
|
148 | + |
|
149 | +if ($_SERVER['HTTP_HOST'] == "localhost") { |
|
150 | + $path_and_file = api_get_path(SYS_PATH).'/crossdomain.xml'; |
|
151 | 151 | if (!file_exists($path_and_file)) { |
152 | - $crossdomain='<?xml version="1.0"?> |
|
152 | + $crossdomain = '<?xml version="1.0"?> |
|
153 | 153 | <!DOCTYPE cross-domain-policy SYSTEM "http://www.adobe.com/xml/dtds/cross-domain-policy.dtd"> |
154 | 154 | <cross-domain-policy> |
155 | 155 | <allow-access-from domain="cdn.pixlr.com" /> |