[TYPO3-commerce] Backend: Display of Articles broken
Franz Steinmetz
franzlst at yahoo.de
Wed Mar 18 20:01:48 CET 2009
OK some debugging infos:
"COMPARE" in the install tool says everything's alright.
As I wrote, when trying to add a category, following error appears:
Fatal error: Cannot use string offset as an array in ***/t3lib/clas.t3lib_befunc.php on line 208
This line is in the function deleteClause, which is called some times before (without any error). In the case the error appears, the argument $table is "sys_languages". The content of the variable $TCA is now EXT:commerce/locallang_db.xml:tx_commerce.ct_filter_attributes select tx_commerce_attributes AND sys_language_uid in (0,-1) ORDER BY title 5 0 30 instead of an array as it should.
When calling the function deleteClause with the argument "sys_languages" from somewhere else, everything is fine (an array with only the default language is returned).
It seems as if $TCA was changed by some code before. Using debug_print_backtrace() in the function just before the error appears returns:
#0 t3lib_BEfunc::deleteClause(sys_language) called at [***/t3lib/class.t3lib_tceforms.php:5736]
#1 t3lib_TCEforms->getAvailableLanguages() called at [***/t3lib/class.t3lib_tceforms.php:2297]
#2 t3lib_TCEforms->getSingleField_typeFlex(tx_commerce_categories, attributes, Array ([parent_category] => 0,[sys_language_uid] => 0,[l18n_parent] => 0,[l18n_diffsource] => ,[hidden] => 0,[starttime] => 0,[endtime] => 0,[fe_group] => 0,[extendToSubpages] => ,[title] => ,[subtitle] => ,[description] => ,[images] => ,[navtitle] => ,[keywords] => ,[ts_config] => ,[attributes] => ,[teaser] => ,[teaserimages] => ,[uid] => NEW49c140d8d6b5d,[pid] => 52), Array ([altName] => ,[palette] => 0,[extra] => ,[pal] => ,[fieldConf] => Array ([exclude] => 1,[l10n_mode] => exclude,[label] => LLL:EXT:commerce/locallang_db.xml:tx_commerce_products.attributes,[config] => Array ([type] => flex,[ds] => Array ([default] =>
1
array
),[form_type] => flex)),[fieldTSConfig] => ,[itemFormElName] => data[tx_commerce_categories][NEW49c140d8d6b5d][attributes],[itemFormElName_file] => data_files[tx_commerce_categories][NEW49c140d8d6b5d][attributes],[itemFormElValue] => ,[itemFormElID] => data_tx_commerce_categories_NEW49c140d8d6b5d_attributes,[onFocus] => ,[label] => Attributes,[fieldChangeFunc] => Array ([TBE_EDITOR_fieldChanged] => TBE_EDITOR.fieldChanged('tx_commerce_categories','NEW49c140d8d6b5d','attributes','data[tx_commerce_categories][NEW49c140d8d6b5d][attributes]');,[alert] => ))) called at [***/t3lib/class.t3lib_tceforms.php:1006]
#3 t3lib_TCEforms->getSingleField_SW(tx_commerce_categories, attributes, Array ([parent_category] => 0,[sys_language_uid] => 0,[l18n_parent] => 0,[l18n_diffsource] => ,[hidden] => 0,[starttime] => 0,[endtime] => 0,[fe_group] => 0,[extendToSubpages] => ,[title] => ,[subtitle] => ,[description] => ,[images] => ,[navtitle] => ,[keywords] => ,[ts_config] => ,[attributes] => ,[teaser] => ,[teaserimages] => ,[uid] => NEW49c140d8d6b5d,[pid] => 52), Array ([altName] => ,[palette] => 0,[extra] => ,[pal] => ,[fieldConf] => Array ([exclude] => 1,[l10n_mode] => exclude,[label] => LLL:EXT:commerce/locallang_db.xml:tx_commerce_products.attributes,[config] => Array ([type] => flex,[ds] => Array ([default] =>
1
array
),[form_type] => flex)),[fieldTSConfig] => ,[itemFormElName] => data[tx_commerce_categories][NEW49c140d8d6b5d][attributes],[itemFormElName_file] => data_files[tx_commerce_categories][NEW49c140d8d6b5d][attributes],[itemFormElValue] => ,[itemFormElID] => data_tx_commerce_categories_NEW49c140d8d6b5d_attributes,[onFocus] => ,[label] => Attributes,[fieldChangeFunc] => Array ([TBE_EDITOR_fieldChanged] => TBE_EDITOR.fieldChanged('tx_commerce_categories','NEW49c140d8d6b5d','attributes','data[tx_commerce_categories][NEW49c140d8d6b5d][attributes]');,[alert] => ))) called at [***/t3lib/class.t3lib_tceforms.php:899]
#4 t3lib_TCEforms->getSingleField(tx_commerce_categories, attributes, Array ([parent_category] => 0,[sys_language_uid] => 0,[l18n_parent] => 0,[l18n_diffsource] => ,[hidden] => 0,[starttime] => 0,[endtime] => 0,[fe_group] => 0,[extendToSubpages] => ,[title] => ,[subtitle] => ,[description] => ,[images] => ,[navtitle] => ,[keywords] => ,[ts_config] => ,[attributes] => ,[teaser] => ,[teaserimages] => ,[uid] => NEW49c140d8d6b5d,[pid] => 52), , 0, , ) called at [***/t3lib/class.t3lib_tceforms.php:569]
#5 t3lib_TCEforms->getMainFields(tx_commerce_categories, Array ([parent_category] => 0,[sys_language_uid] => 0,[l18n_parent] => 0,[l18n_diffsource] => ,[hidden] => 0,[starttime] => 0,[endtime] => 0,[fe_group] => 0,[extendToSubpages] => ,[title] => ,[subtitle] => ,[description] => ,[images] => ,[navtitle] => ,[keywords] => ,[ts_config] => ,[attributes] => ,[teaser] => ,[teaserimages] => ,[uid] => NEW49c140d8d6b5d,[pid] => 52)) called at [***/typo3/alt_doc.php:760]
#6 SC_alt_doc->makeEditForm() called at [***/typo3/alt_doc.php:538]
#7 SC_alt_doc->main() called at [***/typo3/alt_doc.php:1483]
I know too less about the TCA and how to handle it, thus I don't know where to go on searching for mistakes.
Any advice?
Thanks
Franz Steinmetz
franzlst at yahoo.de
http://www.roboshow.de
http://www.jsg-abi2008.de
http://www.kalender.jsg-abi2008.de
----- Ursprüngliche Mail ----
Von: Franz Steinmetz <franzlst at yahoo.de>
An: TYPO3 commerce extension project <typo3-project-commerce at lists.netfielders.de>
Gesendet: Mittwoch, den 18. März 2009, 16:35:17 Uhr
Betreff: Re: [TYPO3-commerce] Backend: Display of Articles broken
Hi Sascha,
yes I did so.
Ciao
Franz Steinmetz
franzlst at yahoo.de
http://www.roboshow.de
http://www.jsg-abi2008.de
http://www.kalender.jsg-abi2008.de
----- Ursprüngliche Mail ----
Von: Sascha Egerer <seg at softvision.de>
An: typo3-project-commerce at lists.netfielders.de
Gesendet: Mittwoch, den 18. März 2009, 09:12:47 Uhr
Betreff: Re: [TYPO3-commerce] Backend: Display of Articles broken
Hi Franz,
did you execute the "UPDATE!" function in the extension Manager? If you
go in the Extension Details in the extension manager there is a Option
"UPDATE!" in the dropdown at the upper left
Greets
Sascha
Franz Steinmetz schrieb:
> Hi,
>
> now I tried to reinstall commerce. After deletion of commerce, I uploaded the 0.9.8 version of commerce.t3x, everything was fine. When updating the new files of the 0.11.8 (revision 17409), the errors came back:
>
> DB Check: Manage reference index -> Update/Check:
> Fatal error: Cannot use string offset as an array in ***/t3lib/class.t3lib_refindex.php on line 402
>
> Adding a category:
> Fatal error: Cannot use string offset as an array in ***/t3lib/class.t3lib_befunc.php on line 208
>
> Adding a product:
> Catchable fatal error: Argument 1 passed to
> t3lib_div::array2xml() must be an array, string given, called in ***/typo3conf/ext/dynaflex/class.dynaflex.php
> on line 196 and defined in ***/t3lib/class.t3lib_div.php on line 2210
>
> Opening sysdelivery:
> Fatal error: Cannot use string offset as an array in ***/typo3conf/ext/commerce/tcafiles/tx_commerce_articles.tca.php on line 444
>
> It's the newest revision of commerce and I haven't changed anything, any idea?
>
> Bye
>
> Franz Steinmetz
>
>
> franzlst at yahoo.de
> http://www.roboshow.de
> http://www.jsg-abi2008.de
> http://www.kalender.jsg-abi2008.de
>
>
>
> ----- Ursprüngliche Mail ----
> Von: Franz Steinmetz <franzlst at yahoo.de>
> An: Typo3 Project Commerce <typo3-project-commerce at lists.netfielders.de>
> Gesendet: Sonntag, den 15. März 2009, 18:07:51 Uhr
> Betreff: [TYPO3-commerce] Backend: Display of Articles broken
>
>
> Hi,
>
> I use commerce 0.11.7 and dynaflex 1.11.0. When I want to edit an article in the Backend (either via clicking on the article in the tree or clicking the pencil of the article in the product view) an error occurs:
>
> Fatal error: Cannot unset string offsets in *******/typo3conf/ext/dynaflex/class.dynaflex.php on line 1094
>
> Nothing more is displayed in this frame. The corresponding line in the file is:
>
> /**
> * Removes an element from a flexform structure.
> *
> * @param array $funcConf: configuration array for a single configuration
> * @return void
> */
> function remove($funcConf = array()) {
> // build path
> $path = $this->getPath($funcConf['inside']);
>
> // get the Data
> $workData = $this->getDataByPath($this->flexData, $path);
>
> // remove the element
> ==> unset($workData[$funcConf['element']]);
>
> // Write back the modified data
> $this->setDataByPath($this->flexData, $path, $workData);
> }
>
> Commenting the line another error appears:
>
> Fatal error: Cannot create references to/from string offsets nor overloaded objects in ******/typo3conf/ext/dynaflex/class.dynaflex.php on line 280
>
> Commenting this one gets:
>
> Fatal error: Cannot use string offset as an array in ******/typo3conf/ext/commerce/tcafiles/tx_commerce_articles.tca.php on line 440
>
> The code here is:
>
> $TCA['tx_commerce_article_prices'] = Array (
> ==> 'ctrl' => $TCA['tx_commerce_article_prices']['ctrl'],
>
> I can't see what shell be wrong here.
>
> I hope you can help me.
>
> Greets
>
> Franz Steinmetz
>
>
> franzlst at yahoo.de
> http://www.roboshow.de
> http://www.jsg-abi2008.de
> http://www.kalender.jsg-abi2008.de
>
>
>
>
> _______________________________________________
> TYPO3-project-commerce mailing list
> TYPO3-project-commerce at lists.netfielders.de
> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-project-commerce
>
>
>
>
_______________________________________________
TYPO3-project-commerce mailing list
TYPO3-project-commerce at lists.netfielders.de
http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-project-commerce
_______________________________________________
TYPO3-project-commerce mailing list
TYPO3-project-commerce at lists.netfielders.de
http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-project-commerce
More information about the TYPO3-project-commerce
mailing list