Questions around the TYPO3 integration and plugins as well as Flow and NeosCMS
Forum rules: Always add your TYPO3/Flow, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
#1907 by trimble
16 Sep 2015, 18:11
Just to be sure. Do you mean, that I replace this block of Code
Code: Select all if( $currentid != '' )
 {
    $catItems = $manager->getPath( $currentid );

    if( $startid != '' )
    {
       foreach( $catItems as $key => $item )
       {
  if( $key == $startid ) {
     break;
  }
  unset( $catItems[$key] );
       }
    }

    if( ( $node = reset( $catItems ) ) === false )
    {
       $msg = sprintf( 'Category with ID "%1$s" not below ID "%2$s"', $currentid, $startid );
       throw new Client_Html_Exception( $msg );
    }
 }
 else if( $startid != '' )
 {
    $node = $manager->getItem( $startid );
    $catItems = array( $node->getId() => $node );
 }
 else
 {
    $node = $manager->getTree( null, array(), MW_Tree_Manager_Abstract::LEVEL_ONE );
    $catItems = array( $node->getId() => $node );
 }   

with this block of code

Code: Select all   
    if( $currentid )
    {
      $catItems = $controller->getCatalogPath( $currentid );

      if( $startid )
      {
         foreach( $catItems as $key => $item )
         {
     if( $key == $startid ) {
      break;
     }
     unset( $catItems[$key] );
         }
      }
    }   


Trimble
#1908 by aimeos
16 Sep 2015, 20:25
trimble wrote:
Code: Select all   
    if( $currentid )
    {
      $catItems = $controller->getCatalogPath( $currentid );

      if( $startid )
      {
         foreach( $catItems as $key => $item )
         {
     if( $key == $startid ) {
      break;
     }
     unset( $catItems[$key] );
         }
      }
    }   



There's another if(reset()) statement afterwards in the new code that you also have to insert.
#1910 by trimble
17 Sep 2015, 10:20
I replaced the code blocks as suggested, cleared the caches in the install tool and got the error message 'A non-recoverable error occured'.

Trimble
#1911 by aimeos
17 Sep 2015, 12:52
trimble wrote:I replaced the code blocks as suggested, cleared the caches in the install tool and got the error message 'A non-recoverable error occured'.


In this case, you can find more information in the madmin_log table.
#1916 by trimble
17 Sep 2015, 14:52
That's in madmin_log table
Code: Select allPHP Warning: reset() expects parameter 1 to be array, null given in /html/typo3/typo3conf/ext/aimeos/Resources/Libraries/aimeos/aimeos-core/client/html/src/Client/Html/Catalog/Filter/Tree/Default.php line 250
#0 [internal function]: TYPO3\CMS\Core\Error\ErrorHandler->handleError(2, 'reset() expects...', '/html/typo3/typ...', 250, Array)
#1 /html/typo3/typo3conf/ext/aimeos/Resources/Libraries/aimeos/aimeos-core/client/html/src/Client/Html/Catalog/Filter/Tree/Default.php(250): reset(NULL)
#2 /html/typo3/typo3conf/ext/aimeos/Resources/Libraries/aimeos/aimeos-core/client/html/src/Client/Html/Catalog/Filter/Tree/Default.php(118): Client_Html_Catalog_Filter_Tree_Default->_setViewParams(Object(MW_View_Default), Array, NULL)
#3 /html/typo3/typo3conf/ext/aimeos/Resources/Libraries/aimeos/aimeos-core/client/html/src/Client/Html/Catalog/Filter/Default.php(220): Client_Html_Catalog_Filter_Tree_Default->getHeader('', Array, NULL)
#4 /html/typo3/typo3conf/ext/aimeos/Classes/Controller/AbstractController.php(142): Client_Html_Catalog_Filter_Default->getHeader()
#5 /html/typo3/typo3conf/ext/aimeos/Classes/Controller/CatalogController.php(32): Aimeos\Aimeos\Controller\AbstractController->getClientOutput(Object(Client_Html_Catalog_Filter_Default))
#6 [internal function]: Aimeos\Aimeos\Controller\CatalogController->filterAction()
#7 /html/typo3/typo3_src-7.4.0/typo3/sysext/extbase/Classes/Mvc/Controller/ActionController.php(259): call_user_func_array(Array, Array)
#8 /html/typo3/typo3_src-7.4.0/typo3/sysext/extbase/Classes/Mvc/Controller/ActionController.php(154): TYPO3\CMS\Extbase\Mvc\Controller\ActionController->callActionMethod()
#9 /html/typo3/typo3_src-7.4.0/typo3/sysext/extbase/Classes/Mvc/Dispatcher.php(70): TYPO3\CMS\Extbase\Mvc\Controller\ActionController->processRequest(Object(TYPO3\CMS\Extbase\Mvc\Web\Request), Object(TYPO3\CMS\Extbase\Mvc\Web\Response))
#10 /html/typo3/typo3_src-7.4.0/typo3/sysext/extbase/Classes/Mvc/Web/FrontendRequestHandler.php(54): TYPO3\CMS\Extbase\Mvc\Dispatcher->dispatch(Object(TYPO3\CMS\Extbase\Mvc\Web\Request), Object(TYPO3\CMS\Extbase\Mvc\Web\Response))
#11 /html/typo3/typo3_src-7.4.0/typo3/sysext/extbase/Classes/Core/Bootstrap.php(196): TYPO3\CMS\Extbase\Mvc\Web\FrontendRequestHandler->handleRequest()
#12 /html/typo3/typo3_src-7.4.0/typo3/sysext/extbase/Classes/Core/Bootstrap.php(185): TYPO3\CMS\Extbase\Core\Bootstrap->handleRequest()
#13 [internal function]: TYPO3\CMS\Extbase\Core\Bootstrap->run('', Array)
#14 /html/typo3/typo3_src-7.4.0/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php(6932): call_user_func_array(Array, Array)
#15 /html/typo3/typo3_src-7.4.0/typo3/sysext/frontend/Classes/ContentObject/UserContentObject.php(39): TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer->callUserFunction('TYPO3\\CMS\\Extba...', Array, '')
#16 /html/typo3/typo3_src-7.4.0/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php(918): TYPO3\CMS\Frontend\ContentObject\UserContentObject->render(Array)
#17 /html/typo3/typo3_src-7.4.0/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php(836): TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer->render(Object(TYPO3\CMS\Frontend\ContentObject\UserContentObject), Array)
#18 /html/typo3/typo3_src-7.4.0/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php(3492): TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer->cObjGetSingle('USER', Array)
#19 /html/typo3/typo3_src-7.4.0/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php(3440): TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController->INTincScript_process(Array)
#20 /html/typo3/typo3_src-7.4.0/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php(3407): TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController->recursivelyReplaceIntPlaceholdersInContent()
#21 /html/typo3/typo3_src-7.4.0/typo3/sysext/frontend/Classes/Http/RequestHandler.php(229): TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController->INTincScript()
#22 /html/typo3/typo3_src-7.4.0/typo3/sysext/core/Classes/Core/Bootstrap.php(288): TYPO3\CMS\Frontend\Http\RequestHandler->handleRequest(Object(TYPO3\CMS\Core\Http\ServerRequest))
#23 /html/typo3/typo3_src-7.4.0/typo3/sysext/frontend/Classes/Http/Application.php(76): TYPO3\CMS\Core\Core\Bootstrap->handleRequest(Object(TYPO3\CMS\Core\Http\ServerRequest))
#24 /html/typo3/typo3_src-7.4.0/index.php(33): TYPO3\CMS\Frontend\Http\Application->run()
#25 [internal function]: {closure}()
#26 /html/typo3/typo3_src-7.4.0/index.php(34): call_user_func(Object(Closure))
#27 {main}


I have appended the default.php with the suggested changes

Regards
Trimble
Attachments
new default.php for typo3 Installation
(3.71 KiB) Downloaded 44 times
#1917 by aimeos
17 Sep 2015, 14:56
trimble wrote:That's in madmin_log table
Code: Select allPHP Warning: reset() expects parameter 1 to be array, null given in /html/typo3/typo3conf/ext/aimeos/Resources/Libraries/aimeos/aimeos-core/client/html/src/Client/Html/Catalog/Filter/Tree/Default.php line 250
#0 [internal function]: TYPO3\CMS\Core\Error\ErrorHandler->handleError(2, 'reset() expects...', '/html/typo3/typ...', 250, Array)


The initialization of the variable is missing. Please have a look in the latest file on Github how it's made there.
#1918 by trimble
17 Sep 2015, 15:29
I try to learn. But it's not easy for me cause I'm not a programmer. :(
I hope I'll find the error with your hints.

Thanks for your patience.

Trimble