Bug #22037
closed
mod.web_list.hideTables does not accept spaces
Added by Calderini Daniel over 14 years ago.
Updated almost 14 years ago.
Description
If you enter the following config in the page tsconfig, table tt_content will be hidden, but not tt_news :
mod.web_list.hideTables = tt_content, tt_news
This is due to the space after the comma. If you remove the space, both tables will be hidden.
(issue imported from #M13386)
Files
Since it works correctly without the space, I don't see a problem here.
This is a "comma seperated list" and seperation with comma works as expected.
You're right, it works as expected. But it is a bit inconsistent with other options.
For example:
mod.web_list.allowedNewTables
mod.web_list.deniedNewTables
Both accept spaces between table names, even if the data type is the same as hideTables (list of tablenames).
So maybe it just needs to be written in doc_core_tsconfig that spaces are not allowed...
IMO whitespace should be allowed as one might want to write something like that:
mod.web_list.hideTables (
tx_extension_table1,
tx_extension_table2,
tx_extension_table3,
tx_extension_table4,
...
)
problem is not the hideTables but t3lib_div::inList which doesn't work with spaces in comma seperated lists
Is there a reason not to use t3lib_div::trimExplode and in_array as it is with allowedNewTables and deniedNewTables? IMO I don't see any (actually I think it should have been that way from the start)?
I posted a patch as the necessary changes are very small and easy to do.
Hi Benjamin,
I did submit it to the list on March 8, but did not receive any feedback at all.
Best wishes, Marcel
Hey Marcel, I just reviewed your patch in the core list. Thank for your patience.
Committed to trunk rev. 7173
Committed to 4.3 rev. 7428
Also available in: Atom
PDF