Fixed bug #16445: Performance Tuning: Replace exec_SELECTgetRows with exec_SELECTgetS...
[Packages/TYPO3.CMS.git] / t3lib / class.t3lib_positionmap.php
1 <?php
2 /***************************************************************
3 * Copyright notice
4 *
5 * (c) 1999-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
6 * All rights reserved
7 *
8 * This script is part of the TYPO3 project. The TYPO3 project is
9 * free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
13 *
14 * The GNU General Public License can be found at
15 * http://www.gnu.org/copyleft/gpl.html.
16 * A copy is found in the textfile GPL.txt and important notices to the license
17 * from the author is found in LICENSE.txt distributed with these scripts.
18 *
19 *
20 * This script is distributed in the hope that it will be useful,
21 * but WITHOUT ANY WARRANTY; without even the implied warranty of
22 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23 * GNU General Public License for more details.
24 *
25 * This copyright notice MUST APPEAR in all copies of the script!
26 ***************************************************************/
27 /**
28 * Contains class for creating a position map.
29 *
30 * $Id$
31 * Revised for TYPO3 3.6 November/2003 by Kasper Skårhøj
32 * XHTML compliant (should be)
33 *
34 * @author Kasper Skårhøj <kasperYYYY@typo3.com>
35 */
36 /**
37 * [CLASS/FUNCTION INDEX of SCRIPT]
38 *
39 *
40 *
41 * 85: class t3lib_positionMap
42 *
43 * SECTION: Page position map:
44 * 132: function positionTree($id,$pageinfo,$perms_clause,$R_URI)
45 * 246: function JSimgFunc($prefix='')
46 * 276: function boldTitle($t_code,$dat,$id)
47 * 293: function onClickEvent($pid,$newPagePID)
48 * 312: function insertlabel()
49 * 324: function linkPageTitle($str,$rec)
50 * 335: function checkNewPageInPid($pid)
51 * 351: function getModConfig($pid)
52 * 366: function insertQuadLines($codes,$allBlank=0)
53 *
54 * SECTION: Content element positioning:
55 * 404: function printContentElementColumns($pid,$moveUid,$colPosList,$showHidden,$R_URI)
56 * 442: function printRecordMap($lines,$colPosArray)
57 * 480: function wrapColumnHeader($str,$vv)
58 * 494: function insertPositionIcon($row,$vv,$kk,$moveUid,$pid)
59 * 511: function onClickInsertRecord($row,$vv,$moveUid,$pid,$sys_lang=0)
60 * 531: function wrapRecordHeader($str,$row)
61 * 541: function getRecordHeader($row)
62 * 554: function wrapRecordTitle($str,$row)
63 *
64 * TOTAL FUNCTIONS: 17
65 * (This index is automatically created/updated by the extension "extdeveval")
66 *
67 */
68
69
70 /**
71 * Position map class - generating a page tree / content element list which links for inserting (copy/move) of records.
72 * Used for pages / tt_content element wizards of various kinds.
73 *
74 * @author Kasper Skårhøj <kasperYYYY@typo3.com>
75 * @package TYPO3
76 * @subpackage t3lib
77 */
78 class t3lib_positionMap {
79
80 // EXTERNAL, static:
81 var $moveOrCopy = 'move';
82 var $dontPrintPageInsertIcons = 0;
83 var $backPath = '';
84 var $depth = 2; // How deep the position page tree will go.
85 var $cur_sys_language; // Can be set to the sys_language uid to select content elements for.
86
87
88 // INTERNAL, dynamic:
89 var $R_URI = ''; // Request uri
90 var $elUid = ''; // Element id.
91 var $moveUid = ''; // tt_content element uid to move.
92
93 // Caching arrays:
94 var $getModConfigCache = array();
95 var $checkNewPageCache = Array();
96
97 // Label keys:
98 var $l_insertNewPageHere = 'insertNewPageHere';
99 var $l_insertNewRecordHere = 'insertNewRecordHere';
100
101 var $modConfigStr = 'mod.web_list.newPageWiz';
102
103
104 /*************************************
105 *
106 * Page position map:
107 *
108 **************************************/
109
110 /**
111 * Creates a "position tree" based on the page tree.
112 * Notice: A class, "localPageTree" must exist and probably it is an extension class of the t3lib_pageTree class. See "db_new.php" in the core for an example.
113 *
114 * @param integer Current page id
115 * @param array Current page record.
116 * @param string Page selection permission clause.
117 * @param string Current REQUEST_URI
118 * @return string HTML code for the tree.
119 */
120 function positionTree($id, $pageinfo, $perms_clause, $R_URI) {
121 global $LANG, $BE_USER;
122
123 // Make page tree object:
124 $t3lib_pageTree = t3lib_div::makeInstance('localPageTree');
125 $t3lib_pageTree->init(' AND ' . $perms_clause);
126 $t3lib_pageTree->addField('pid');
127
128 // Initialize variables:
129 $this->R_URI = $R_URI;
130 $this->elUid = $id;
131
132 // Create page tree, in $this->depth levels.
133 $t3lib_pageTree->getTree($pageinfo['pid'], $this->depth);
134 if (!$this->dontPrintPageInsertIcons) {
135 $code .= $this->JSimgFunc();
136 }
137
138 // Initialize variables:
139 $saveBlankLineState = array();
140 $saveLatestUid = array();
141 $latestInvDepth = $this->depth;
142
143 // Traverse the tree:
144 foreach ($t3lib_pageTree->tree as $cc => $dat) {
145
146 // Make link + parameters.
147 $latestInvDepth = $dat['invertedDepth'];
148 $saveLatestUid[$latestInvDepth] = $dat;
149 if (isset($t3lib_pageTree->tree[$cc - 1])) {
150 $prev_dat = $t3lib_pageTree->tree[$cc - 1];
151
152 // If current page, subpage?
153 if ($prev_dat['row']['uid'] == $id) {
154 if (!$this->dontPrintPageInsertIcons && $this->checkNewPageInPid($id) && !($prev_dat['invertedDepth'] > $t3lib_pageTree->tree[$cc]['invertedDepth'])) { // 1) It must be allowed to create a new page and 2) If there are subpages there is no need to render a subpage icon here - it'll be done over the subpages...
155 $code .= '<span class="nobr">' .
156 $this->insertQuadLines($dat['blankLineCode']) .
157 '<img src="clear.gif" width="18" height="8" align="top" alt="" />' .
158 '<a href="#" onclick="' . htmlspecialchars($this->onClickEvent($id, $id, 1)) . '" onmouseover="' . htmlspecialchars('changeImg(\'mImgSubpage' . $cc . '\',0);') . '" onmouseout="' . htmlspecialchars('changeImg(\'mImgSubpage' . $cc . '\',1);') . '">' .
159 '<img' . t3lib_iconWorks::skinImg($this->backPath, 'gfx/newrecord_marker_d.gif', 'width="281" height="8"') . ' name="mImgSubpage' . $cc . '" border="0" align="top" title="' . $this->insertlabel() . '" alt="" />' .
160 '</a></span><br />';
161 }
162 }
163
164 if ($prev_dat['invertedDepth'] > $t3lib_pageTree->tree[$cc]['invertedDepth']) { // If going down
165 $prevPid = $t3lib_pageTree->tree[$cc]['row']['pid'];
166 } elseif ($prev_dat['invertedDepth'] < $t3lib_pageTree->tree[$cc]['invertedDepth']) { // If going up
167 // First of all the previous level should have an icon:
168 if (!$this->dontPrintPageInsertIcons && $this->checkNewPageInPid($prev_dat['row']['pid'])) {
169 $prevPid = (-$prev_dat['row']['uid']);
170 $code .= '<span class="nobr">' .
171 $this->insertQuadLines($dat['blankLineCode']) .
172 '<img src="clear.gif" width="18" height="1" align="top" alt="" />' .
173 '<a href="#" onclick="' . htmlspecialchars($this->onClickEvent($prevPid, $prev_dat['row']['pid'], 2)) . '" onmouseover="' . htmlspecialchars('changeImg(\'mImgAfter' . $cc . '\',0);') . '" onmouseout="' . htmlspecialchars('changeImg(\'mImgAfter' . $cc . '\',1);') . '">' .
174 '<img' . t3lib_iconWorks::skinImg($this->backPath, 'gfx/newrecord_marker_d.gif', 'width="281" height="8"') . ' name="mImgAfter' . $cc . '" border="0" align="top" title="' . $this->insertlabel() . '" alt="" />' .
175 '</a></span><br />';
176 }
177
178 // Then set the current prevPid
179 $prevPid = -$prev_dat['row']['pid'];
180 } else {
181 $prevPid = -$prev_dat['row']['uid']; // In on the same level
182 }
183 } else {
184 $prevPid = $dat['row']['pid']; // First in the tree
185 }
186 if (!$this->dontPrintPageInsertIcons && $this->checkNewPageInPid($dat['row']['pid'])) {
187 $code .= '<span class="nobr">' .
188 $this->insertQuadLines($dat['blankLineCode']) .
189 '<a href="#" onclick="' . htmlspecialchars($this->onClickEvent($prevPid, $dat['row']['pid'], 3)) . '" onmouseover="' . htmlspecialchars('changeImg(\'mImg' . $cc . '\',0);') . '" onmouseout="' . htmlspecialchars('changeImg(\'mImg' . $cc . '\',1);') . '">' .
190 '<img' . t3lib_iconWorks::skinImg($this->backPath, 'gfx/newrecord_marker_d.gif', 'width="281" height="8"') . ' name="mImg' . $cc . '" border="0" align="top" title="' . $this->insertlabel() . '" alt="" />' .
191 '</a></span><br />';
192 }
193
194 // The line with the icon and title:
195 $t_code = '<span class="nobr">' .
196 $dat['HTML'] .
197 $this->linkPageTitle($this->boldTitle(htmlspecialchars(t3lib_div::fixed_lgd_cs($dat['row']['title'], $BE_USER->uc['titleLen'])), $dat, $id), $dat['row']) .
198 '</span><br />';
199 $code .= $t_code;
200 }
201
202 // If the current page was the last in the tree:
203 $prev_dat = end($t3lib_pageTree->tree);
204 if ($prev_dat['row']['uid'] == $id) {
205 if (!$this->dontPrintPageInsertIcons && $this->checkNewPageInPid($id)) {
206 $code .= '<span class="nobr">' .
207 $this->insertQuadLines($saveLatestUid[$latestInvDepth]['blankLineCode'], 1) .
208 '<img src="clear.gif" width="18" height="8" align="top" alt="" />' .
209 '<a href="#" onclick="' . $this->onClickEvent($id, $id, 4) . '" onmouseover="' . htmlspecialchars('changeImg(\'mImgSubpage' . $cc . '\',0);') . '" onmouseout="' . htmlspecialchars('changeImg(\'mImgSubpage' . $cc . '\',1);') . '">' .
210 '<img' . t3lib_iconWorks::skinImg($this->backPath, 'gfx/newrecord_marker_d.gif', 'width="281" height="8"') . ' name="mImgSubpage' . $cc . '" border="0" align="top" title="' . $this->insertlabel() . '" alt="" />' .
211 '</a></span><br />';
212 }
213 }
214
215 for ($a = $latestInvDepth; $a <= $this->depth; $a++) {
216 $dat = $saveLatestUid[$a];
217 $prevPid = (-$dat['row']['uid']);
218 if (!$this->dontPrintPageInsertIcons && $this->checkNewPageInPid($dat['row']['pid'])) {
219 $code .= '<span class="nobr">' .
220 $this->insertQuadLines($dat['blankLineCode'], 1) .
221 '<a href="#" onclick="' . htmlspecialchars($this->onClickEvent($prevPid, $dat['row']['pid'], 5)) . '" onmouseover="' . htmlspecialchars('changeImg(\'mImgEnd' . $a . '\',0);') . '" onmouseout="' . htmlspecialchars('changeImg(\'mImgEnd' . $a . '\',1);') . '">' .
222 '<img' . t3lib_iconWorks::skinImg($this->backPath, 'gfx/newrecord_marker_d.gif', 'width="281" height="8"') . ' name="mImgEnd' . $a . '" border="0" align="top" title="' . $this->insertlabel() . '" alt="" />' .
223 '</a></span><br />';
224 }
225 }
226
227 return $code;
228 }
229
230 /**
231 * Creates the JavaScritp for insert new-record rollover image
232 *
233 * @param string Insert record image prefix.
234 * @return string <script> section
235 */
236 function JSimgFunc($prefix = '') {
237 $code .= $GLOBALS['TBE_TEMPLATE']->wrapScriptTags('
238
239 var img_newrecord_marker=new Image();
240 img_newrecord_marker.src = "' . t3lib_iconWorks::skinImg($this->backPath, 'gfx/newrecord' . $prefix . '_marker.gif', '', 1) . '";
241
242 var img_newrecord_marker_d=new Image();
243 img_newrecord_marker_d.src = "' . t3lib_iconWorks::skinImg($this->backPath, 'gfx/newrecord' . $prefix . '_marker_d.gif', '', 1) . '";
244
245 function changeImg(name,d) { //
246 if (document[name]) {
247 if (d) {
248 document[name].src = img_newrecord_marker_d.src;
249 } else {
250 document[name].src = img_newrecord_marker.src;
251 }
252 }
253 }
254 ');
255 return $code;
256 }
257
258 /**
259 * Wrap $t_code in bold IF the $dat uid matches $id
260 *
261 * @param string Title string
262 * @param array Infomation array with record array inside.
263 * @param integer The current id.
264 * @return string The title string.
265 */
266 function boldTitle($t_code, $dat, $id) {
267 if ($dat['row']['uid'] == $id) {
268 $t_code = '<strong>' . $t_code . '</strong>';
269 }
270 return $t_code;
271 }
272
273 /**
274 * Creates the onclick event for the insert-icons.
275 *
276 * TSconfig mod.web_list.newPageWiz.overrideWithExtension may contain an extension which provides a module
277 * to be used instead of the normal create new page wizard.
278 *
279 * @param integer The pid.
280 * @param integer New page id.
281 * @return string Onclick attribute content
282 */
283 function onClickEvent($pid, $newPagePID) {
284 $TSconfigProp = $this->getModConfig($newPagePID);
285
286 if ($TSconfigProp['overrideWithExtension']) {
287 if (t3lib_extMgm::isLoaded($TSconfigProp['overrideWithExtension'])) {
288 $onclick = "window.location.href='" . t3lib_extMgm::extRelPath($TSconfigProp['overrideWithExtension']) . 'mod1/index.php?cmd=crPage&positionPid=' . $pid . "';";
289 return $onclick;
290 }
291 }
292
293 $params = '&edit[pages][' . $pid . ']=new&returnNewPageId=1';
294 return t3lib_BEfunc::editOnClick($params, '', $this->R_URI);
295 }
296
297 /**
298 * Get label, htmlspecialchars()'ed
299 *
300 * @return string The localized label for "insert new page here"
301 */
302 function insertlabel() {
303 global $LANG;
304 return $LANG->getLL($this->l_insertNewPageHere, 1);
305 }
306
307 /**
308 * Wrapping page title.
309 *
310 * @param string Page title.
311 * @param array Page record (?)
312 * @return string Wrapped title.
313 */
314 function linkPageTitle($str, $rec) {
315 return $str;
316 }
317
318 /**
319 * Checks if the user has permission to created pages inside of the $pid page.
320 * Uses caching so only one regular lookup is made - hence you can call the function multiple times without worrying about performance.
321 *
322 * @param integer Page id for which to test.
323 * @return boolean
324 */
325 function checkNewPageInPid($pid) {
326 global $BE_USER;
327 if (!isset($this->checkNewPageCache[$pid])) {
328 $pidInfo = t3lib_BEfunc::getRecord('pages', $pid);
329 $this->checkNewPageCache[$pid] = ($BE_USER->isAdmin() || $BE_USER->doesUserHaveAccess($pidInfo, 8));
330 }
331 return $this->checkNewPageCache[$pid];
332 }
333
334 /**
335 * Returns module configuration for a pid.
336 *
337 * @param integer Page id for which to get the module configuration.
338 * @return array The properties of teh module configuration for the page id.
339 * @see onClickEvent()
340 */
341 function getModConfig($pid) {
342 if (!isset($this->getModConfigCache[$pid])) {
343 // Acquiring TSconfig for this PID:
344 $this->getModConfigCache[$pid] = t3lib_BEfunc::getModTSconfig($pid, $this->modConfigStr);
345 }
346 return $this->getModConfigCache[$pid]['properties'];
347 }
348
349 /**
350 * Insert half/quad lines.
351 *
352 * @param string keywords for which lines to insert.
353 * @param boolean If true all lines are just blank clear.gifs
354 * @return string HTML content.
355 */
356 function insertQuadLines($codes, $allBlank = 0) {
357 $codeA = t3lib_div::trimExplode(',', $codes . ",line", 1);
358
359 $lines = array();
360 foreach ($codeA as $code) {
361 if ($code == "blank" || $allBlank) {
362 $lines[] = '<img src="clear.gif" width="18" height="8" align="top" alt="" />';
363 } else {
364 $lines[] = '<img' . t3lib_iconWorks::skinImg($this->backPath, 'gfx/ol/halfline.gif', 'width="18" height="8"') . ' align="top" alt="" />';
365 }
366 }
367 return implode('', $lines);
368 }
369
370
371 /*************************************
372 *
373 * Content element positioning:
374 *
375 **************************************/
376
377 /**
378 * Creates HTML for inserting/moving content elements.
379 *
380 * @param integer page id onto which to insert content element.
381 * @param integer Move-uid (tt_content element uid?)
382 * @param string List of columns to show
383 * @param boolean If not set, then hidden/starttime/endtime records are filtered out.
384 * @param string Request URI
385 * @return string HTML
386 */
387 function printContentElementColumns($pid, $moveUid, $colPosList, $showHidden, $R_URI) {
388 $this->R_URI = $R_URI;
389 $this->moveUid = $moveUid;
390 $colPosArray = t3lib_div::trimExplode(',', $colPosList, 1);
391
392 $lines = array();
393 foreach ($colPosArray as $kk => $vv) {
394 $res = $GLOBALS['TYPO3_DB']->exec_SELECTquery(
395 '*',
396 'tt_content',
397 'pid=' . intval($pid) .
398 ($showHidden ? '' : t3lib_BEfunc::BEenableFields('tt_content')) .
399 ' AND colPos=' . intval($vv) .
400 (strcmp($this->cur_sys_language, '') ? ' AND sys_language_uid=' . intval($this->cur_sys_language) : '') .
401 t3lib_BEfunc::deleteClause('tt_content') .
402 t3lib_BEfunc::versioningPlaceholderClause('tt_content'),
403 '',
404 'sorting'
405 );
406 $lines[$kk] = array();
407 $lines[$kk][] = $this->insertPositionIcon('', $vv, $kk, $moveUid, $pid);
408 while ($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res)) {
409 t3lib_BEfunc::workspaceOL('tt_content', $row);
410 if (is_array($row)) {
411 $lines[$kk][] = $this->wrapRecordHeader($this->getRecordHeader($row), $row);
412 $lines[$kk][] = $this->insertPositionIcon($row, $vv, $kk, $moveUid, $pid);
413 }
414 }
415 $GLOBALS['TYPO3_DB']->sql_free_result($res);
416 }
417 return $this->printRecordMap($lines, $colPosArray);
418 }
419
420 /**
421 * Creates the table with the content columns
422 *
423 * @param array Array with arrays of lines for each column
424 * @param array Column position array
425 * @return string HTML
426 */
427 function printRecordMap($lines, $colPosArray) {
428 $row1 = '';
429 $row2 = '';
430 $count = t3lib_div::intInRange(count($colPosArray), 1);
431
432 // Traverse the columns here:
433 foreach ($colPosArray as $kk => $vv) {
434 $row1 .= '<td align="center" width="' . round(100 / $count) . '%"><span class="uppercase"><strong>' .
435 $this->wrapColumnHeader($GLOBALS['LANG']->sL(t3lib_BEfunc::getLabelFromItemlist('tt_content', 'colPos', $vv), 1), $vv) .
436 '</strong></span></td>';
437 $row2 .= '<td valign="top" nowrap="nowrap">' .
438 implode('<br />', $lines[$kk]) .
439 '</td>';
440 }
441
442 $table = '
443
444 <!--
445 Map of records in columns:
446 -->
447 <table border="0" cellpadding="0" cellspacing="1" id="typo3-ttContentList">
448 <tr class="bgColor5">' . $row1 . '</tr>
449 <tr>' . $row2 . '</tr>
450 </table>
451
452 ';
453
454 return $this->JSimgFunc('2') . $table;
455 }
456
457 /**
458 * Wrapping the column header
459 *
460 * @param string Header value
461 * @param string Column info.
462 * @return string
463 * @see printRecordMap()
464 */
465 function wrapColumnHeader($str, $vv) {
466 return $str;
467 }
468
469 /**
470 * Creates a linked position icon.
471 *
472 * @param array Element row.
473 * @param string Column position value.
474 * @param integer Column key.
475 * @param integer Move uid
476 * @param integer PID value.
477 * @return string
478 */
479 function insertPositionIcon($row, $vv, $kk, $moveUid, $pid) {
480 $cc = hexdec(substr(md5($row['uid'] . '-' . $vv . '-' . $kk), 0, 4));
481 return '<a href="#" onclick="' . htmlspecialchars($this->onClickInsertRecord($row, $vv, $moveUid, $pid, $this->cur_sys_language)) . '" onmouseover="' . htmlspecialchars('changeImg(\'mImg' . $cc . '\',0);') . '" onmouseout="' . htmlspecialchars('changeImg(\'mImg' . $cc . '\',1);') . '">' .
482 '<img' . t3lib_iconWorks::skinImg($this->backPath, 'gfx/newrecord2_marker_d.gif', 'width="100" height="8"') . ' name="mImg' . $cc . '" border="0" align="top" title="' . $GLOBALS['LANG']->getLL($this->l_insertNewRecordHere, 1) . '" alt="" />' .
483 '</a>';
484 }
485
486 /**
487 * Create on-click event value.
488 *
489 * @param array The record.
490 * @param string Column position value.
491 * @param integer Move uid
492 * @param integer PID value.
493 * @param integer System language (not used currently)
494 * @return string
495 */
496 function onClickInsertRecord($row, $vv, $moveUid, $pid, $sys_lang = 0) {
497 $table = 'tt_content';
498 if (is_array($row)) {
499 $location = 'tce_db.php?cmd[' . $table . '][' . $moveUid . '][' . $this->moveOrCopy . ']=-' . $row['uid'] . '&prErr=1&uPT=1&vC=' . $GLOBALS['BE_USER']->veriCode();
500 } else {
501 $location = 'tce_db.php?cmd[' . $table . '][' . $moveUid . '][' . $this->moveOrCopy . ']=' . $pid . '&data[' . $table . '][' . $moveUid . '][colPos]=' . $vv . '&prErr=1&vC=' . $GLOBALS['BE_USER']->veriCode();
502 }
503 // $location.='&redirect='.rawurlencode($this->R_URI); // returns to prev. page
504 $location .= '&uPT=1&redirect=' . rawurlencode(t3lib_div::getIndpEnv('REQUEST_URI')); // This redraws screen
505
506 return 'window.location.href=\'' . $location . '\';return false;';
507 }
508
509 /**
510 * Wrapping the record header (from getRecordHeader())
511 *
512 * @param string HTML content
513 * @param array Record array.
514 * @return string HTML content
515 */
516 function wrapRecordHeader($str, $row) {
517 return $str;
518 }
519
520 /**
521 * Create record header (includes teh record icon, record title etc.)
522 *
523 * @param array Record row.
524 * @return string HTML
525 */
526 function getRecordHeader($row) {
527 $line = t3lib_iconWorks::getSpriteIconForRecord('tt_content', $row, array('title' => htmlspecialchars(t3lib_BEfunc::getRecordIconAltText($row, 'tt_content'))));
528 $line .= t3lib_BEfunc::getRecordTitle('tt_content', $row, TRUE);
529 return $this->wrapRecordTitle($line, $row);
530 }
531
532 /**
533 * Wrapping the title of the record.
534 *
535 * @param string The title value.
536 * @param array The record row.
537 * @return string Wrapped title string.
538 */
539 function wrapRecordTitle($str, $row) {
540 return '<a href="' . htmlspecialchars(t3lib_div::linkThisScript(array('uid' => intval($row['uid']), 'moveUid' => ''))) . '">' . $str . '</a>';
541 }
542 }
543
544 if (defined('TYPO3_MODE') && $TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['t3lib/class.t3lib_positionmap.php']) {
545 include_once($TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['t3lib/class.t3lib_positionmap.php']);
546 }
547 ?>