TYPO3: Exception 1316104317 - Controller can not be determined
When you want to add a content element "plug-in" to a page in TYPO3, the following error may occur in TYPO3:
TYPO3 Exception 1316104317
The default controller for extension ... and plugin ... can not be determined.
The following situations can lead to this error:
Pay attention to Upper Camel Case in TypoScript
If you embed the plugin into the website via TypoScript, then you should pay attention to the UpperCamelCase notation. A wrong spelling can lead to the above mentioned errors, e.g.
lib.marker = USER_INT
lib.marker {
userFunc = Extcode\Cart\Controller\Cart\CartPreviewController->show
# Pay attention to upper camel case here!
extensionName = Cart
vendorName = Extcode
pluginName = MiniCart
}
Switching the plugin type in the content element
If you have inserted the plugin as a normal content element, then changing the plugin type can cause the error. e.g. if you change from the News plugin to Cart.
There are two solutions for this:
- Delete content element and create it again with the plugin that you need.
- Manual editing of the record in the database: In the table tt_content look for the plugin record and delete the content of the field "pi_flexform".
Check if the extension has a controller
The error can occur if you forget to define the controller in ext_localconf.php while developing the extension or if you have an error in the code of the definition. The following is an example of how a controller should look like:
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin(
//assuming your extension is in typo3conf/ext/your_ext folder
'YourExt',
// Plugin name
'Pi1',
// An array of controller-action combinations. The first one found is the default one.
[
\YourVendor\YourExt\Controller\YourController::class => 'index,new,create,edit,update'
],
// An array of non-cacheable controller-action-combinations (they must already be enabled)
[
\YourVendor\YourExt\Controller\YourController::class => 'new,create,edit,update'
],
);
Source: typo3.org: TYPO3 Exception 1316104317
Were we able to help you?
Did this article help you?
We would be happy to receive your feedback!