[CLEANUP] Remove backpath in calls to BackendUtility::editOnClick 02/38302/2
authorMarkus Klein <klein.t3@reelworx.at>
Fri, 27 Mar 2015 12:29:38 +0000 (13:29 +0100)
committerBenjamin Mack <benni@typo3.org>
Fri, 27 Mar 2015 23:38:24 +0000 (00:38 +0100)
Releases: master
Resolves: #66092
Change-Id: I776160cc89453cf2dbc65037c1422f93db496379
Reviewed-on: http://review.typo3.org/38302
Reviewed-by: Benjamin Kott <info@bk2k.info>
Tested-by: Benjamin Kott <info@bk2k.info>
Reviewed-by: Benjamin Mack <benni@typo3.org>
Tested-by: Benjamin Mack <benni@typo3.org>
12 files changed:
typo3/sysext/backend/Classes/Controller/ContentElement/ElementInformationController.php
typo3/sysext/backend/Classes/Controller/PageLayoutController.php
typo3/sysext/backend/Classes/View/PageLayoutView.php
typo3/sysext/core/Classes/Database/QueryView.php
typo3/sysext/filelist/Classes/FileList.php
typo3/sysext/frontend/Classes/Controller/TranslationStatusController.php
typo3/sysext/info_pagetsconfig/Classes/Controller/InfoPageTyposcriptConfigController.php
typo3/sysext/linkvalidator/Classes/Report/LinkValidatorReport.php
typo3/sysext/recordlist/Classes/RecordList/AbstractDatabaseRecordList.php
typo3/sysext/recordlist/Classes/RecordList/DatabaseRecordList.php
typo3/sysext/tstemplate/Classes/Controller/TypoScriptTemplateInformationModuleFunctionController.php
typo3/sysext/version/Classes/Controller/VersionModuleController.php

index eb93857..451ea40 100644 (file)
@@ -545,7 +545,7 @@ class ElementInformationController {
                }
 
                // Edit button
-               $editOnClick = BackendUtility::editOnClick('&edit[' . $table . '][' . $uid . ']=edit', $GLOBALS['BACK_PATH']);
+               $editOnClick = BackendUtility::editOnClick('&edit[' . $table . '][' . $uid . ']=edit');
                $pageActionIcons = '
                        <a class="btn btn-default btn-sm" href="#" onclick="' . htmlspecialchars($editOnClick) . '">
                                ' . IconUtility::getSpriteIcon('actions-document-open') . '
@@ -638,7 +638,7 @@ class ElementInformationController {
                        $parentRecord = BackendUtility::getRecord('pages', $record['pid']);
                        $icon = (is_array($record)) ? IconUtility::getSpriteIconForRecord($row['tablename'], $record) : '';
                        $actions = $this->getRecordActions($row['tablename'], $row['recuid']);
-                       $editOnClick = BackendUtility::editOnClick('&edit[' . $row['tablename'] . '][' . $row['recuid'] . ']=edit', $GLOBALS['BACK_PATH']);
+                       $editOnClick = BackendUtility::editOnClick('&edit[' . $row['tablename'] . '][' . $row['recuid'] . ']=edit');
                        $infoData[] = '
                                <tr>
                                        <td class="col-icon">
@@ -714,7 +714,7 @@ class ElementInformationController {
                        $parentRecord = BackendUtility::getRecord('pages', $record['pid']);
                        $icon = IconUtility::getSpriteIconForRecord($row['tablename'], $record);
                        $actions = $this->getRecordActions($row['ref_table'], $row['ref_uid']);
-                       $editOnClick = BackendUtility::editOnClick('&edit[' . $row['ref_table'] . '][' . $row['ref_uid'] . ']=edit', $GLOBALS['BACK_PATH']);
+                       $editOnClick = BackendUtility::editOnClick('&edit[' . $row['ref_table'] . '][' . $row['ref_uid'] . ']=edit');
                        $infoData[] = '
                                <tr>
                                        <td class="col-icon">
index 49d047a..13a03d6 100644 (file)
@@ -1119,11 +1119,7 @@ class PageLayoutController {
                                                'sys_language_uid'
                                        );
 
-                                       $editLanguageOnClick = htmlspecialchars(
-                                               BackendUtility::editOnClick(
-                                               '&edit[pages_language_overlay][' . $overlayRecord['uid'] . ']=edit',
-                                               $GLOBALS['BACK_PATH'])
-                                       );
+                                       $editLanguageOnClick = htmlspecialchars(BackendUtility::editOnClick('&edit[pages_language_overlay][' . $overlayRecord['uid'] . ']=edit'));
                                        $buttons['edit_language'] = '<a href="#" ' .
                                                'onclick="' . $editLanguageOnClick . '"' .
                                                'title="' . $GLOBALS['LANG']->getLL('editPageLanguageOverlayProperties', TRUE) . '">' .
@@ -1133,9 +1129,7 @@ class PageLayoutController {
 
 
                                // Edit page properties
-                               $editPageOnClick = htmlspecialchars(
-                                       BackendUtility::editOnClick('&edit[pages][' . $this->id . ']=edit', $GLOBALS['BACK_PATH'])
-                               );
+                               $editPageOnClick = htmlspecialchars(BackendUtility::editOnClick('&edit[pages][' . $this->id . ']=edit'));
                                $buttons['edit_page'] = '<a href="#" ' .
                                        'onclick="' . $editPageOnClick . '"' .
                                        'title="' . $GLOBALS['LANG']->getLL('editPageProperties', TRUE) . '">' .
index 04969cf..0ed9f04 100644 (file)
@@ -334,7 +334,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                                                $this->getLanguageService()->getLL('editThisColumn'),
                                                rtrim(trim($this->getLanguageService()->sL(BackendUtility::getItemLabel('pages', $field))), ':')
                                        );
-                                       $eI = '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, $this->backPath, ''))
+                                       $eI = '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params))
                                                . '" title="' . htmlspecialchars($iTitle) . '">' . IconUtility::getSpriteIcon('actions-document-open') . '</a>';
                                } else {
                                        $eI = '';
@@ -673,7 +673,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                                                        'pages_language_overlay',
                                                        $lpRecord['uid']
                                                ) . $viewLink . ($this->getBackendUser()->check('tables_modify', 'pages_language_overlay')
-                                                               ? '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, $this->backPath))
+                                                               ? '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params))
                                                                        . '" title="' . $this->getLanguageService()->getLL('edit', TRUE) . '">'
                                                                        . IconUtility::getSpriteIcon('actions-document-open') . '</a>'
                                                                : ''
@@ -840,7 +840,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                        if (!$this->getPageLayoutController()->current_sys_language) {
                                if ($this->ext_CALC_PERMS & Permission::PAGE_EDIT) {
                                        $bArray[0] = $this->getPageLayoutController()->doc->t3Button(
-                                               BackendUtility::editOnClick('&edit[pages][' . $id . ']=edit', $this->backPath, ''),
+                                               BackendUtility::editOnClick('&edit[pages][' . $id . ']=edit'),
                                                $this->getLanguageService()->getLL('editPageProperties')
                                        );
                                }
@@ -853,8 +853,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                                                'AND sys_language_uid=' . (int)$this->getPageLayoutController()->current_sys_language
                                        );
                                        $bArray[0] = $this->getPageLayoutController()->doc->t3Button(
-                                               BackendUtility::editOnClick('&edit[pages_language_overlay][' . $languageOverlayRecord['uid'] . ']=edit',
-                                                       $this->backPath, ''),
+                                               BackendUtility::editOnClick('&edit[pages_language_overlay][' . $languageOverlayRecord['uid'] . ']=edit'),
                                                $this->getLanguageService()->getLL('editPageProperties_curLang')
                                        );
                                }
@@ -955,10 +954,9 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                        . '</tr>';
                // Column's titles
                if ($this->doEdit) {
-                       $theData['__cmds__'] = '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick(
-                                       '&edit[' . $table . '][' . $this->id . ']=new',
-                                       $this->backPath
-                               )) . '" title="' . $this->getLanguageService()->getLL('new', TRUE) . '">'
+                       $onClick = BackendUtility::editOnClick('&edit[' . $table . '][' . $this->id . ']=new');
+                       $theData['__cmds__'] = '<a href="#" onclick="' . htmlspecialchars($onClick) . '" '
+                               . 'title="' . $this->getLanguageService()->getLL('new', TRUE) . '">'
                                . IconUtility::getSpriteIcon('actions-document-new') . '</a>';
                }
                $out .= $this->addelement(1, '', $theData, ' class="c-headLine"', 15);
@@ -980,8 +978,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                                        $Nrow = $this->dataFields($this->fieldArray, $table, $row, $Nrow);
                                        // Attach edit icon
                                        if ($this->doEdit) {
-                                               $Nrow['__editIconLink__'] = '<a href="#" onclick="' . htmlspecialchars(
-                                                               BackendUtility::editOnClick($params, $this->backPath))
+                                               $Nrow['__editIconLink__'] = '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params))
                                                        . '" title="' . $this->getLanguageService()->getLL('edit', TRUE) . '">'
                                                        . IconUtility::getSpriteIcon('actions-document-open') . '</a>';
                                        } else {
@@ -1193,7 +1190,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                                        if ($this->getBackendUser()->doesUserHaveAccess($row, 2)) {
                                                $params = '&edit[pages][' . $row['uid'] . ']=edit';
                                                $eI = '<a href="#" onclick="'
-                                                       . htmlspecialchars(BackendUtility::editOnClick($params, $this->backPath, ''))
+                                                       . htmlspecialchars(BackendUtility::editOnClick($params))
                                                        . '" title="' . $this->getLanguageService()->getLL('editThisPage', TRUE) . '">'
                                                        . IconUtility::getSpriteIcon('actions-document-open') . '</a>';
                                        } else {
@@ -1239,7 +1236,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                        // Edit whole of column:
                        if ($editParams) {
                                $iconsArr['edit'] = '<a href="#" onclick="'
-                                       . htmlspecialchars(BackendUtility::editOnClick($editParams, $this->backPath)) . '" title="'
+                                       . htmlspecialchars(BackendUtility::editOnClick($editParams)) . '" title="'
                                        . $this->getLanguageService()->getLL('editColumn', TRUE) . '">'
                                        . IconUtility::getSpriteIcon('actions-document-open') . '</a>';
                        }
@@ -1324,7 +1321,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                                $params = '&edit[tt_content][' . $this->tt_contentData['nextThree'][$row['uid']] . ']=edit';
                                $out .= '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick(
                                                $params,
-                                               $this->backPath,
+                                               '',
                                                GeneralUtility::getIndpEnv('REQUEST_URI') . '#element-tt_content-' . $row['uid']
                                        )) . '" title="' . htmlspecialchars($this->nextThree > 1
                                                ? sprintf($this->getLanguageService()->getLL('nextThree'), $this->nextThree)
@@ -1730,7 +1727,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                                . '&returnUrl=' . rawurlencode(GeneralUtility::getIndpEnv('REQUEST_URI')) . '\';';
                } else {
                        $onClick = BackendUtility::editOnClick('&edit[tt_content][' . $id . ']=new&defVals[tt_content][colPos]='
-                               . $colPos . '&defVals[tt_content][sys_language_uid]=' . $sys_language, $this->backPath);
+                               . $colPos . '&defVals[tt_content][sys_language_uid]=' . $sys_language);
                }
                return $onClick;
        }
@@ -1749,7 +1746,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                $onClick = '';
                if ($this->doEdit && $this->getBackendUser()->recordEditAccessInternals('tt_content', $row)) {
                        // Setting onclick action for content link:
-                       $onClick = BackendUtility::editOnClick('&edit[tt_content][' . $row['uid'] . ']=edit', $this->backPath);
+                       $onClick = BackendUtility::editOnClick('&edit[tt_content][' . $row['uid'] . ']=edit');
                }
                // Return link
                return $onClick ? '<a href="#" onclick="' . htmlspecialchars($onClick)
index 37ebe94..8d0955a 100644 (file)
@@ -543,7 +543,7 @@ class QueryView {
                $out .= '<td><div class="btn-group">';
                if (!$row['deleted']) {
                        $out .= '<a class="btn btn-default" href="#" onClick="top.launchView(\'' . $table . '\',' . $row['uid'] . ',\'' . $GLOBALS['BACK_PATH'] . '\');return false;">' . \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIcon('status-dialog-information') . '</a>';
-                       $out .= '<a class="btn btn-default" href="#" onClick="' . BackendUtility::editOnClick($params, $GLOBALS['BACK_PATH'], (GeneralUtility::getIndpEnv('REQUEST_URI') . GeneralUtility::implodeArrayForUrl('SET', (array)GeneralUtility::_POST('SET')))) . '">' . \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIcon('actions-document-open') . '</a>';
+                       $out .= '<a class="btn btn-default" href="#" onClick="' . BackendUtility::editOnClick($params, '', (GeneralUtility::getIndpEnv('REQUEST_URI') . GeneralUtility::implodeArrayForUrl('SET', (array)GeneralUtility::_POST('SET')))) . '">' . \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIcon('actions-document-open') . '</a>';
                } else {
                        $out .= '<a class="btn btn-default" href="' . GeneralUtility::linkThisUrl(BackendUtility::getModuleUrl('tce_db'), array(
                                        ('cmd[' . $table . '][' . $row['uid'] . '][undelete]') => '1',
index 5db45c8..01ec07a 100644 (file)
@@ -596,7 +596,7 @@ class FileList extends AbstractRecordList {
                                $data = array(
                                        'sys_file_metadata' => array($metaData['uid'] => 'edit')
                                );
-                               $editOnClick = BackendUtility::editOnClick(GeneralUtility::implodeArrayForUrl('edit', $data), $GLOBALS['BACK_PATH'], $this->listUrl());
+                               $editOnClick = BackendUtility::editOnClick(GeneralUtility::implodeArrayForUrl('edit', $data), '', $this->listUrl());
                                $title = htmlspecialchars($this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:cm.editMetadata'));
                                $code = '<a href="#" title="' . $title . '" onclick="' . htmlspecialchars($editOnClick) . '">' . GeneralUtility::fixed_lgd_cs($code, $this->fixedL) . '</a>';
                        }
@@ -691,7 +691,7 @@ class FileList extends AbstractRecordList {
                                                                                $data = array(
                                                                                        'sys_file_metadata' => array($translations[$languageId]['uid'] => 'edit')
                                                                                );
-                                                                               $editOnClick = BackendUtility::editOnClick(GeneralUtility::implodeArrayForUrl('edit', $data), $GLOBALS['BACK_PATH'], $this->listUrl());
+                                                                               $editOnClick = BackendUtility::editOnClick(GeneralUtility::implodeArrayForUrl('edit', $data), '', $this->listUrl());
                                                                                $languageCode .= '<a href="#" class="btn btn-default" onclick="' . htmlspecialchars($editOnClick) . '">' . $flagButtonIcon . '</a>';
                                                                        } else {
                                                                                $href = $GLOBALS['SOBE']->doc->issueCommand(
index 18be7fa..1ed9788 100644 (file)
@@ -132,9 +132,8 @@ class TranslationStatusController extends \TYPO3\CMS\Backend\Module\AbstractFunc
                        $info = '';
                        $editUid = $data['row']['uid'];
                        $params = '&edit[pages][' . $editUid . ']=edit';
-                       $info .= '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick(
-                                       $params, $GLOBALS['BACK_PATH'])
-                               ) . '" title="' . $lang->sL(
+                       $info .= '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params))
+                               . '" title="' . $lang->sL(
                                        'LLL:EXT:cms/web_info/locallang.xlf:lang_renderl10n_editDefaultLanguagePage'
                                ) . '">' . IconUtility::getSpriteIcon('actions-document-open') . '</a>';
                        $info .= str_replace('###LANG_UID###', '0', $viewPageLink);
@@ -178,9 +177,8 @@ class TranslationStatusController extends \TYPO3\CMS\Backend\Module\AbstractFunc
                                                $info = '';
                                                $editUid = $row['uid'];
                                                $params = '&edit[pages_language_overlay][' . $editUid . ']=edit';
-                                               $info .= '<a href="#" onclick="' . htmlspecialchars(
-                                                               BackendUtility::editOnClick($params, $GLOBALS['BACK_PATH'])
-                                                       ) . '" title="' . $lang->sL(
+                                               $info .= '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params))
+                                                       . '" title="' . $lang->sL(
                                                                'LLL:EXT:cms/web_info/locallang.xlf:lang_renderl10n_editLanguageOverlayRecord'
                                                        ) . '">' . IconUtility::getSpriteIcon('actions-document-open') . '</a>';
                                                $info .= str_replace('###LANG_UID###', $langRow['uid'], $viewPageLink);
@@ -217,9 +215,8 @@ class TranslationStatusController extends \TYPO3\CMS\Backend\Module\AbstractFunc
                $tCells[] = '<td>' . $lang->sL('LLL:EXT:cms/web_info/locallang.xlf:lang_renderl10n_page') . ':</td>';
                if (is_array($langRecUids[0])) {
                        $params = '&edit[pages][' . implode(',', $langRecUids[0]) . ']=edit&columnsOnly=title,nav_title,l18n_cfg,hidden';
-                       $editIco = '<a href="#" onclick="' . htmlspecialchars(
-                                       BackendUtility::editOnClick($params, $GLOBALS['BACK_PATH'])
-                               ) . '" title="' . $lang->sL(
+                       $editIco = '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params))
+                               . '" title="' . $lang->sL(
                                        'LLL:EXT:cms/web_info/locallang.xlf:lang_renderl10n_editPageProperties'
                                ) . '">' . IconUtility::getSpriteIcon('actions-document-new') . '</a>';
                } else {
@@ -237,9 +234,8 @@ class TranslationStatusController extends \TYPO3\CMS\Backend\Module\AbstractFunc
                                        $params = '&edit[pages_language_overlay][' .
                                                implode(',', $langRecUids[$langRow['uid']]) .
                                                ']=edit&columnsOnly=title,nav_title,hidden';
-                                       $tCells[] = '<td><a href="#" onclick="' . htmlspecialchars(
-                                                       BackendUtility::editOnClick($params, $GLOBALS['BACK_PATH'])
-                                               ) . '" title="' . $lang->sL(
+                                       $tCells[] = '<td><a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params))
+                                               . '" title="' . $lang->sL(
                                                        'LLL:EXT:cms/web_info/locallang.xlf:lang_renderl10n_editLangOverlays'
                                                ) . '">' . IconUtility::getSpriteIcon('actions-document-open') . '</a></td>';
                                } else {
@@ -250,9 +246,8 @@ class TranslationStatusController extends \TYPO3\CMS\Backend\Module\AbstractFunc
                                        $newOL_js[$langRow['uid']] .
                                        '+\'&columnsOnly=title,hidden,sys_language_uid&defVals[pages_language_overlay][sys_language_uid]=' .
                                        $langRow['uid'];
-                               $tCells[] = '<td><a href="#" onclick="' . htmlspecialchars(
-                                               BackendUtility::editOnClick($params, $GLOBALS['BACK_PATH'])
-                                       ) . '" title="' . $lang->sL(
+                               $tCells[] = '<td><a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params))
+                                       . '" title="' . $lang->sL(
                                                'LLL:EXT:cms/web_info/locallang.xlf:lang_getlangsta_createNewTranslationHeaders'
                                        ) . '">' . IconUtility::getSpriteIcon('actions-document-new') . '</a></td>';
                        }
index 6c8c5ae..da0b3f0 100644 (file)
@@ -110,7 +110,7 @@ class InfoPageTyposcriptConfigController extends \TYPO3\CMS\Backend\Module\Abstr
                                                        $pTitle = $this->pObj->doc->getHeader('pages', $row, '', FALSE);
                                                        $editIdList = substr($k, 4);
                                                        $params = '&edit[pages][' . $editIdList . ']=edit&columnsOnly=TSconfig';
-                                                       $onclickUrl = BackendUtility::editOnClick($params, $GLOBALS['BACK_PATH'], '');
+                                                       $onclickUrl = BackendUtility::editOnClick($params);
                                                        $editIcon = '<a href="#" onclick="' . htmlspecialchars($onclickUrl) . '" title="' . $this->getLanguageService()->getLL('editTSconfig', TRUE) . '">' . \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIcon('actions-document-open') . '</a>';
                                                }
                                                $TScontent = nl2br(htmlspecialchars(trim($v) . LF));
@@ -126,7 +126,7 @@ class InfoPageTyposcriptConfigController extends \TYPO3\CMS\Backend\Module\Abstr
                                }
                                if (count($pUids)) {
                                        $params = '&edit[pages][' . implode(',', $pUids) . ']=edit&columnsOnly=TSconfig';
-                                       $onclickUrl = BackendUtility::editOnClick($params, $GLOBALS['BACK_PATH'], '');
+                                       $onclickUrl = BackendUtility::editOnClick($params);
                                        $editIcon = '<a href="#" onclick="' . htmlspecialchars($onclickUrl) . '" title="' . $this->getLanguageService()->getLL('editTSconfig_all', TRUE) . '">' . \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIcon('actions-document-open') . '<strong>' . $this->getLanguageService()->getLL('editTSconfig_all', TRUE) . '</strong>' . '</a>';
                                } else {
                                        $editIcon = '';
index c770e1b..befada8 100644 (file)
@@ -468,7 +468,7 @@ class LinkValidatorReport extends \TYPO3\CMS\Backend\Module\AbstractFunctionModu
                $actionLink = '<a href="#" onclick="';
                $actionLink .= htmlspecialchars(BackendUtility::editOnClick(
                        '&edit[' . $table . '][' . $row['record_uid'] . ']=edit',
-                       $GLOBALS['BACK_PATH'],
+                       '',
                        $requestUri
                ));
                $actionLink .= '" title="' . $this->getLanguageService()->getLL('list.edit') . '">';
index 6f022b7..8a7053d 100644 (file)
@@ -802,8 +802,7 @@ class AbstractDatabaseRecordList extends AbstractRecordList {
                                // "Edit" link: ( Only if permissions to edit the page-record of the content of the parent page ($this->id)
                                if ($permsEdit) {
                                        $params = '&edit[' . $table . '][' . $row['uid'] . ']=edit';
-                                       $code = '<a href="#" onclick="' . htmlspecialchars(
-                                                       BackendUtility::editOnClick($params, $this->backPath, -1)) . '" title="' . $lang->getLL('edit', TRUE) . '">' . $code . '</a>';
+                                       $code = '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, '', -1)) . '" title="' . $lang->getLL('edit', TRUE) . '">' . $code . '</a>';
                                }
                                break;
                        case 'show':
index a264a46..0e3d1a5 100644 (file)
@@ -252,7 +252,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                        if ($localCalcPerms & Permission::PAGE_EDIT && !empty($this->id)) {
                                // Edit
                                $params = '&edit[pages][' . $this->pageRow['uid'] . ']=edit';
-                               $onClick = htmlspecialchars(BackendUtility::editOnClick($params, $this->backPath, -1));
+                               $onClick = htmlspecialchars(BackendUtility::editOnClick($params, '', -1));
                                $buttons['edit'] = '<a href="#" onclick="' . $onClick . '" title="'
                                        . $lang->getLL('editPage', TRUE) . '">'
                                        . IconUtility::getSpriteIcon('actions-page-open') . '</a>';
@@ -897,7 +897,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                                                $editIdList = implode(',', $currentIdList);
                                                $editIdList = '\'+editList(\'' . $table . '\',\'' . $editIdList . '\')+\'';
                                                $params = '&edit[' . $table . '][' . $editIdList . ']=edit';
-                                               $onClick = htmlspecialchars(BackendUtility::editOnClick($params, $this->backPath, -1));
+                                               $onClick = htmlspecialchars(BackendUtility::editOnClick($params, '', -1));
                                                $cells['edit'] = '<a class="btn btn-default" href="#" onclick="' . $onClick . '" title="'
                                                        . $lang->getLL('clip_editMarked', TRUE) . '">'
                                                        . IconUtility::getSpriteIcon('actions-document-open') . '</a>';
@@ -964,7 +964,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                                                                if ($table == 'pages_language_overlay') {
                                                                        $params .= '&overrideVals[pages_language_overlay][doktype]=' . (int)$this->pageRow['doktype'];
                                                                }
-                                                               $icon = '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, $this->backPath, -1))
+                                                               $icon = '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, '', -1))
                                                                        . '" title="' . $lang->getLL('new', TRUE) . '">' . $spriteIcon . '</a>';
                                                        }
                                                }
@@ -975,7 +975,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                                                                $editIdList = '\'+editList(\'' . $table . '\',\'' . $editIdList . '\')+\'';
                                                        }
                                                        $params = '&edit[' . $table . '][' . $editIdList . ']=edit&columnsOnly=' . implode(',', $this->fieldArray);
-                                                       $icon .= '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, $this->backPath, -1))
+                                                       $icon .= '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, '', -1))
                                                                . '" title="' . $lang->getLL('editShownColumns', TRUE) . '">'
                                                                . IconUtility::getSpriteIcon('actions-document-open') . '</a>';
                                                        $icon = '<div class="btn-group" role="group">' . $icon . '</div>';
@@ -1016,7 +1016,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                                                        }
                                                        $params = '&edit[' . $table . '][' . $editIdList . ']=edit&columnsOnly=' . $fCol;
                                                        $iTitle = sprintf($lang->getLL('editThisColumn'), $sortLabel);
-                                                       $theData[$fCol] .= '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, $this->backPath, -1))
+                                                       $theData[$fCol] .= '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, '', -1))
                                                                . '" title="' . htmlspecialchars($iTitle) . '">'
                                                                . IconUtility::getSpriteIcon('actions-document-open') . '</a>';
                                                }
@@ -1207,7 +1207,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                if ($permsEdit) {
                        $params = '&edit[' . $table . '][' . $row['uid'] . ']=edit';
                        $spriteIcon = ($GLOBALS['TCA'][$table]['ctrl']['readOnly'] ? 'actions-document-open-read-only' : 'actions-document-open');
-                       $editAction = '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, $this->backPath, -1))
+                       $editAction = '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, '', -1))
                                . '" title="' . $this->getLanguageService()->getLL('edit', TRUE) . '">' . IconUtility::getSpriteIcon($spriteIcon) . '</a>';
                        $this->addActionToCellGroup($cells, $editAction, 'edit');
                }
@@ -1265,7 +1265,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                                if ($table !== 'pages' && $this->calcPerms & Permission::CONTENT_EDIT || $table === 'pages' && $this->calcPerms & Permission::PAGE_NEW) {
                                        if ($this->showNewRecLink($table)) {
                                                $params = '&edit[' . $table . '][' . -($row['_MOVE_PLH'] ? $row['_MOVE_PLH_uid'] : $row['uid']) . ']=new';
-                                               $newAction = '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, $this->backPath, -1))
+                                               $newAction = '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, '', -1))
                                                        . '" title="' . $this->getLanguageService()->getLL('new' . ($table == 'pages ' ? 'Page' : 'Record'), TRUE) . '">'
                                                        . ($table == 'pages' ? IconUtility::getSpriteIcon('actions-page-new') : IconUtility::getSpriteIcon('actions-document-new')) . '</a>';
                                                $this->addActionToCellGroup($cells, $newAction, 'new');
index 1dbabc3..0b2f7ff 100644 (file)
@@ -64,7 +64,7 @@ class TypoScriptTemplateInformationModuleFunctionController extends AbstractFunc
                        $startAnchor = '<a href="' . htmlspecialchars(($aHref . '&e[' . $field . ']=1')) . '">';
                } else {
                        $params = '&columnsOnly=' . $field . '&createExtension=0' . '&edit[sys_template][' . $id . ']=edit';
-                       $editOnClick = BackendUtility::editOnClick($params, $GLOBALS['BACK_PATH'], '');
+                       $editOnClick = BackendUtility::editOnClick($params);
                        $startAnchor = '<a href="#" onclick="' . $editOnClick . '">';
                }
                $icon = IconUtility::getSpriteIcon(
@@ -275,7 +275,7 @@ class TypoScriptTemplateInformationModuleFunctionController extends AbstractFunc
                        $outCode = '<div class="table-fit"><table class="table table-striped table-hover">' . $outCode . '</table></div>';
 
                        // Edit all icon:
-                       $editOnClick = BackendUtility::editOnClick(rawurlencode('&createExtension=0') . '&amp;edit[sys_template][' . $tplRow['uid'] . ']=edit', $GLOBALS['BACK_PATH'], '');
+                       $editOnClick = BackendUtility::editOnClick(rawurlencode('&createExtension=0') . '&amp;edit[sys_template][' . $tplRow['uid'] . ']=edit');
                        $icon = IconUtility::getSpriteIcon('actions-document-open', array('title' => $lang->getLL('editTemplateRecord'))) . $lang->getLL('editTemplateRecord');
                        $outCode .= '<br /><a href="#" onclick="' . $editOnClick . '"><strong>' . $icon . '</strong></a>';
                        $theOutput .= $this->pObj->doc->section('', $outCode);
index c8befae..0dfdf33 100644 (file)
@@ -362,7 +362,7 @@ class VersionModuleController extends \TYPO3\CMS\Backend\Module\BaseScriptClass
                                        <td>' . $row['t3ver_stage'] . '</td>
                                        <td>' . $row['t3ver_count'] . '</td>
                                        <td>' . $row['pid'] . '</td>
-                                       <td nowrap="nowrap"><a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick(('&edit[' . $this->table . '][' . $row['uid'] . ']=edit&columnsOnly=t3ver_label'), $this->doc->backPath)) . '" title="' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:cm.edit', TRUE) . '">' . IconUtility::getSpriteIcon('actions-document-open') . '</a>' . htmlspecialchars($row['t3ver_label']) . '</td>
+                                       <td nowrap="nowrap"><a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick('&edit[' . $this->table . '][' . $row['uid'] . ']=edit&columnsOnly=t3ver_label')) . '" title="' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:cm.edit', TRUE) . '">' . IconUtility::getSpriteIcon('actions-document-open') . '</a>' . htmlspecialchars($row['t3ver_label']) . '</td>
                                        <td class="version-diff-1"><input type="radio" name="diff_1" value="' . $row['uid'] . '"' . ($diff_1 == $row['uid'] ? ' checked="checked"' : '') . '/></td>
                                        <td class="version-diff-2"><input type="radio" name="diff_2" value="' . $row['uid'] . '"' . ($diff_2 == $row['uid'] ? ' checked="checked"' : '') . '/></td>
                                </tr>';
@@ -472,7 +472,7 @@ class VersionModuleController extends \TYPO3\CMS\Backend\Module\BaseScriptClass
         */
        public function adminLinks($table, $row) {
                // Edit link:
-               $adminLink = '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick(('&edit[' . $table . '][' . $row['uid'] . ']=edit'), $this->doc->backPath)) . '" title="' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:cm.edit', TRUE) . '">' . IconUtility::getSpriteIcon('actions-document-open') . '</a>';
+               $adminLink = '<a href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick('&edit[' . $table . '][' . $row['uid'] . ']=edit')) . '" title="' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:cm.edit', TRUE) . '">' . IconUtility::getSpriteIcon('actions-document-open') . '</a>';
                // Delete link:
                $adminLink .= '<a href="' . htmlspecialchars($this->doc->issueCommand(('&cmd[' . $table . '][' . $row['uid'] . '][delete]=1'))) . '" title="' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:cm.delete', TRUE) . '">' . IconUtility::getSpriteIcon('actions-edit-delete') . '</a>';
                if ($table === 'pages') {