Commit d5a497e5 authored by Benni Mack's avatar Benni Mack Committed by Georg Ringer
Browse files

[TASK] Deprecate uc->classicPageEditMode and editRegularContentFromId

There is some leftover, never-called code in a regular TYPO3 instance
regarding the old uc->classicPageEditMode option and its companion
functionality in EditDocumentController->editRegularContentFromId
which has been marked for deprecation.

Resolves: #66905
Releases: master
Change-Id: I0a428e411b9d7a0a646c7356d773a369c9397dde
Reviewed-on: http://review.typo3.org/39474


Reviewed-by: Wouter Wolters's avatarWouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Andreas Fernandez's avatarAndreas Fernandez <typo3@scripting-base.de>
Tested-by: Andreas Fernandez's avatarAndreas Fernandez <typo3@scripting-base.de>
Reviewed-by: Georg Ringer's avatarGeorg Ringer <georg.ringer@gmail.com>
Tested-by: Georg Ringer's avatarGeorg Ringer <georg.ringer@gmail.com>
parent 358706a3
......@@ -689,9 +689,7 @@ class ClickMenu {
// If another module was specified, replace the default Page module with the new one
$newPageModule = trim($this->backendUser->getTSConfigVal('options.overridePageModule'));
$pageModule = BackendUtility::isModuleSetInTBE_MODULES($newPageModule) ? $newPageModule : 'web_layout';
$editOnClick = '';
$loc = 'top.content.list_frame';
$addParam = '';
$theIcon = 'actions-document-open';
$link = BackendUtility::getModuleUrl('record_edit', array(
......@@ -700,15 +698,8 @@ class ClickMenu {
if ($this->iParts[0] === 'pages' && $this->iParts[1] && $this->backendUser->check('modules', $pageModule)) {
$this->editPageIconSet = TRUE;
if ($this->backendUser->uc['classicPageEditMode']) {
$addParam = '&editRegularContentFromId=' . (int)$this->iParts[1];
} else {
$editOnClick = 'if(' . $loc . '){' . $loc . '.location.href=' . GeneralUtility::quoteJSvalue($link . '&returnUrl=') . '+top.rawurlencode(' . $this->frameLocation(($loc . '.document')) . '.pathname+' . $this->frameLocation(($loc . '.document')) . '.search)+' . GeneralUtility::quoteJSvalue($addParam) . ';}';
}
}
if (!$editOnClick) {
$editOnClick = 'if(' . $loc . '){' . $loc . '.location.href=' . GeneralUtility::quoteJSvalue($link . '&returnUrl=') . '+top.rawurlencode(' . $this->frameLocation(($loc . '.document')) . '.pathname+' . $this->frameLocation(($loc . '.document')) . '.search)+' . GeneralUtility::quoteJSvalue($addParam) . ';}';
}
$editOnClick = 'if(' . $loc . '){' . $loc . '.location.href=' . GeneralUtility::quoteJSvalue($link . '&returnUrl=') . '+top.rawurlencode(' . $this->frameLocation(($loc . '.document')) . '.pathname+' . $this->frameLocation(($loc . '.document')) . '.search);}';
return $this->linkItem($this->label('edit'), IconUtility::getSpriteIcon($theIcon), $editOnClick . ';');
}
......
......@@ -164,6 +164,7 @@ class EditDocumentController {
* (NORMAL column/default language) from that page into the form!
*
* @var int
* @deprecated since TYPO3 CMS 7, will be removed with TYPO3 CMS 8
*/
public $editRegularContentFromId;
......@@ -1513,8 +1514,10 @@ class EditDocumentController {
* Function, which populates the internal editconf array with editing commands for all tt_content elements from the normal column in normal language from the page pointed to by $this->editRegularContentFromId
*
* @return void
* @deprecated since TYPO3 CMS 7, will be removed with TYPO3 CMS 8
*/
public function editRegularContentFromId() {
GeneralUtility::logDeprecatedFunction();
$res = $GLOBALS['TYPO3_DB']->exec_SELECTquery('uid', 'tt_content', 'pid=' . (int)$this->editRegularContentFromId . BackendUtility::deleteClause('tt_content') . BackendUtility::versioningPlaceholderClause('tt_content') . ' AND colPos=0 AND sys_language_uid=0', '', 'sorting');
if ($GLOBALS['TYPO3_DB']->sql_num_rows($res)) {
$ecUids = array();
......
===========================================================================================
Deprecation: #66905 - Deprecate uc->classicPageEditMode and editRegularContentFromId option
===========================================================================================
Description
===========
The BE-User uc option "classicPageEditMode" which was used prior to TYPO3 CMS 4.0 has been removed some time ago.
The functionality ``editRegularContentFromId`` which was then triggered in EditDocumentController has been marked
for deprecation.
Impact
======
Any direct calls using ``editRegularContentFromId`` via GET parameter or calling ``editRegularContentFromId()``
directly from a third-party extension will output a deprecation message.
Affected Installations
======================
Any installation using third-party code to restore the old behaviour.
Migration
=========
Remove calls to the functionality.
......@@ -223,7 +223,6 @@ var typoscriptWords = {
'classesCharacter': 'reserved',
'classesImage': 'reserved',
'classesParagraph': 'reserved',
'classicPageEditMode': 'reserved',
'clear': 'reserved',
'clearCache': 'reserved',
'clearCache_disable': 'reserved',
......@@ -1545,7 +1544,6 @@ var typoscriptWords = {
'classesCharacter': 'reserved',
'classesImage': 'reserved',
'classesParagraph': 'reserved',
'classicPageEditMode': 'reserved',
'clear': 'reserved',
'clearCache': 'reserved',
'clearCache_disable': 'reserved',
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment