After migrating our site from version 8 LTS to version 9 LTS, I have some configuration problems with the routing.
With RealURL we use the fixedPostVars, 'noMatch' => 'bypass'.
For example with this URL
http://Mysite/my-page/mysubpage
?tx_extension[action]=show
&tx_extension[controller]=Researchers
&tx_extension[fullName]=FirstNameWithÉ-LastName
&tx_extension[id]=37
&cHash=f077e6ab99d456c1d0431603186c32cf
We would like to have
http://Mysite/my-page/mysubpage/FirstNameWithC-LastNameWithe/37
For now I can get
http://Mysite/my-page/mysubpage/FirstNameWith%2527-LastName/37
?tx_extension%5Baction%5D=show
&tx_extension%5Bcontroller%5D=Researchers
&cHash=067d606ab30ace24e7cf347bdf89b011
I tried several configurations without success.
So how can I do to hide the controller, the action and the cHash.
Also, how to handle accented characters in URL.
This is my configuration for routeEnhancers
ListResearchers:
type: Plugin
limitToPages:
- 2706
- 2707
routePath: '/{name}/{uid}'
namespace: 'tx_extension'
_arguments:
name: 'fullName'
uid: 'id'
fullName
has a too huge value space to be there without requirements
/aspects
. That will produce ?cHash
.
In your case (string), you can use the PersistedAliasMapper
or write a custom aspect.
uid
will need requirements
. (If you want to use it. You could get rid of it with PersistedAliasMapper
)