Issue Bug Closed

#15671Can't add content when logged in as non-admin

Steven Weiss 02/19/06, 13:05 updated 08/12/06, 14:17

Description

Hi,
when you are logged in as non-admin and want to add a new content element with the green templavoila page module there’s always the message

“Sorry, you didn’t have proper permissions to perform this change”

although the user rights are fine!

After some debugging I found out that the problem is in the core:

in t3lib/class.t3lib_tcemain.php there’s addDefaultPermittedLanguageIfNotSet(). The following line will produce the error:

$rows = array_merge(array(‘uid’=>0),$GLOBALS[‘TYPO3_DB’]->exec_SELECTgetRows(‘uid’,‘sys_language’,‘pid=0’.t3lib_BEfunc::deleteClause(‘sys_language’)),array(‘uid’=>-1));

It should be
array_merge(array(array(‘uid’=>0)),$GLOBALS[‘TYPO3_DB’]->exec_SELECTgetRows(‘uid’,‘sys_language’,‘pid=0’.t3lib_BEfunc::deleteClause(‘sys_language’)));

Then it works ;-)
(issue imported from #M2628)

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.