Forked from johannessteu/TYPO3 Neos plugin: route configuration
Last active
February 2, 2018 14:46
-
-
Save svparijs/34863e18cdf0ff769b67 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
prototype(Vendor.Name:FooPlugin) < prototype(TYPO3.Neos:Plugin) | |
prototype(Vendor.Name:FooPlugin) { | |
package = 'Vendor.Name' | |
controller = 'Standard' | |
action = 'index' | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Put this in your global Routes.yaml | |
# !!! This must be included before the TYPO3 Neos-Routes | |
# | |
- | |
name: 'Foo routes' | |
uriPattern: '<VendorNameFooRoutes>' | |
defaults: | |
'@package': 'Vendor.Name' | |
'@format' : 'html' | |
subRoutes: | |
VendorNameFooRoutes: | |
package: Vendor.Name | |
# | |
# Put this in your packages Routes.yaml | |
# | |
- | |
name: 'Basic Route' | |
uriPattern: '{node}/custom-part/{--vendor_name-fooplugin.object}.{@format}' | |
defaults: | |
'@package': 'TYPO3.Neos' | |
'@controller': 'Frontend\Node' | |
'@format': 'html' | |
'@action': 'show' | |
'--vendor_name-fooplugin': | |
'@package': 'Vendor.Name' | |
'@controller': 'Standard' | |
'@action': 'index' | |
'@format': 'html' | |
routeParts: | |
node: | |
handler: TYPO3\Neos\Routing\FrontendNodeRoutePartHandler | |
'--vendor_name-fooplugin.object': | |
objectType: '\Vendor\Name\Domain\Model\Object' | |
uriPattern: '{name}' | |
appendExceedingArguments: TRUE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
URL: | |
http://example.com/nodename.html? | |
--vendor_name-fooplugin[package]=vendor.name& | |
--vendor_name-fooplugin[controller]=standard& | |
--vendor_name-fooplugin[action]=index& | |
--vendor_name-fooplugin[object][__identity]=4de2cc9c-79c0-55e7-310e-91c5ae2fea19 | |
should result in | |
http://example.com/nodename/custom-part/objectname.html | |
while objectname is dynamic |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment