Project

General

Profile

Actions

Bug #77918

open

imagecols = 1 doesn't work, if disabled in BE interface

Added by Freddy Tripold almost 8 years ago. Updated 11 months ago.

Status:
Needs Feedback
Priority:
Must have
Assignee:
-
Category:
TypoScript
Target version:
-
Start date:
2016-09-12
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
9
PHP Version:
5.6
Tags:
Complexity:
Is Regression:
No
Sprint Focus:
On Location Sprint

Description

TCEFORM.tt_content.imagecols = 1 in PageTS doesn't work. A workaround with
mod.wizards.newContentElement.wizardItems.common.elements.textmedia.tt_content_defValues.imagecols = 1
only works if you start with the textmedia. If you start with custom ce or any other ce, imagecols = 2.

With the same workaround for the custom ce slider

mod.wizards.newContentElement.wizardItems.common.elements.slider{
icon = slider.gif
title = Slider
description = Slider
tt_content_defValues {
CType = Slider
imagecols = 1

}
}

you can change the value to 1, but if the gallerySettings are invisible, mod.wizard... don't work, imagecols is 2. Same behavior, if you change between the content elements.
So, there is no way to make custom content elements with only one image and without the gallerySettings. The imagecols are always 2.

TYPO 7.6.10 and fluid_styled_content


Related issues 3 (0 open3 closed)

Related to TYPO3 Core - Bug #75233: TCAdefaults imagecols doesn't work alwaysClosed2016-03-22

Actions
Related to TYPO3 Core - Bug #63049: TCAdefaults imagecols doesn't workClosed2014-11-18

Actions
Related to TYPO3 Core - Bug #77889: Default value for Number of ColumnsClosed2016-09-08

Actions
Actions #1

Updated by Freddy Tripold almost 8 years ago

As described here http://stackoverflow.com/questions/39393978/typo3-v7-6-default-value-for-number-of-columns , this is a bug since 6.2
A workaround will be to add $GLOBALS['TCA']['tt_content']['columns']['imagecols']['config']['default'] = 1;

Actions #2

Updated by Freddy Tripold almost 8 years ago

The correct syntax for TCEFORM should be TCEFORM.tt_content.imagecols.config.default = 1 as described here https://docs.typo3.org/typo3cms/TSconfigReference/7.6/PageTsconfig/TCEform/
But this make no difference only TCAdefaults.tt_content.imagecols = 1 works as expected.

Actions #3

Updated by Riccardo De Contardi about 7 years ago

I can confirm that only

TCAdefaults.tt_content.imagecols = 1

is working on latest master

Actions #4

Updated by Riccardo De Contardi almost 7 years ago

  • Category set to TypoScript
Actions #5

Updated by taywa gmbh over 4 years ago

  • Subject changed from imagecols = 1 doesn't work to imagecols = 1 doesn't work, if disabled in BE interface
  • TYPO3 Version changed from 7 to 9

Still present in 9.5.7:

In page config:

TCEFORM.tt_content.imagecols.removeItems = 2,3,4,5,6,7,8

# ## 1 imagecols is default
TCAdefaults.tt_content.imagecols = 1

or

#TCEFORM.tt_content.imagecols.config.default = 1

TCEFORM.tt_content.imagecols.disabled = 1

In CType "image" content, this leads to imagecols = 2, if imagecols.disabled = 1

To set $GLOBALS['TCA']['tt_content']['columns']['imagecols']['config']['default'] = 1; I would need to make a new, own extension for this project.

Workaround for me is just not disable it, then on save it will be set to the desired imagecols = 1.

Actions #6

Updated by Benni Mack 12 months ago

  • Sprint Focus set to On Location Sprint
Actions #7

Updated by Benni Mack 12 months ago

  • Status changed from New to Needs Feedback

This bug has been solved, I think with at least v11 as we set the TCAdefaults properly in DataHandler.

I cannot reproduce this in a v12 installation anymore.

Actions #8

Updated by Riccardo De Contardi 11 months ago

I performed the following test on TYPO3 11.5.30 and 12.4.5

1) Create a Page
2) Modify its Page TSConfig (See table below for all the configurations tested)
3) Create the following CE:

- Images Only
- Text and Images
- Text and Media

4) I looked on both the content of the dropdown "Number of columns [imagecols]" AND on the actual value saved on the DB on the "imagecols" field of the "tt_content" table.

The results are listed on the following table

- the results are the same for all the three CE tested
- the results are the same for both TYPO3 versions.

TS Config Option selected on the [imagecols] dropdown in backend actual value of the [imagecols] field on DB
TCEFORM.tt_content.imagecols.removeItems = 2,3,4,5,6,7,8
TCAdefaults.tt_content.imagecols = 1
1 (only option available) 1
TCEFORM.tt_content.imagecols.removeItems = 2,3,4,5,6,7,8
TCEFORM.tt_content.imagecols.config.default = 1
1 (only option available) 1
TCEFORM.tt_content.imagecols.removeItems = 2,3,4,5,6,7,8
TCAdefaults.tt_content.imagecols = 1
TCEFORM.tt_content.imagecols.disabled = 1
(not visible) 1
TCEFORM.tt_content.imagecols.removeItems = 2,3,4,5,6,7,8
TCEFORM.tt_content.imagecols.config.default = 1
TCEFORM.tt_content.imagecols.disabled = 1
(not visible) 2 (*)

(*) Note:

If I remove the line TCEFORM.tt_content.imagecols.disabled = 1 from the TS Config, the backend dropdown Number of Columns [imagecols]
shows 1 as value !!!! the value shown is wrong , as the value saved on the DB is actually 2 Only when you save the CE the value will be updated and becomes 1.

Actions

Also available in: Atom PDF