Typo3 realurl: standard controller und action definieren

Ich habe eine extbase Extension, die mir auf einer bestimmten Seite eine Liste mit Artikeln gefiltert nach Kategorie anzeigt. Die URL sah vor realurl so aus:
http://www.domain.com/artikelsammlung/haushalt.html?tx_somethingarticles_categorydetail[articleCategory]=101&tx_somethingarticles_categorydetail[action]=showByArticleCategory&tx_somethingarticles_categorydetail[controller]=Article

Daraus wollte ich nun folgendes machen: http://www.domain.com/artikelsammlung/haushalt/ARTIKELNAME.html denn controller und action sind hier sowieso immer dieselben. Mein reaulurl_conf.php sieht so aus:

'fixedPostVars' => array(
	'artikelhaushaltConfiguration' => array(
		array(
			'GETvar' => 'tx_somethingarticles_categorydetail[controller]',
			'noMatch' => 'bypass'
		),
		array(
			'GETvar' => 'tx_somethingarticles_categorydetail[action]',
			'noMatch' => 'bypass'
		),
		array(
			'GETvar' => 'tx_somethingarticles_categorydetail[articleCategory]',
			'lookUpTable' => array(
				...
			)
		),
	),
	24 => 'artikelhaushaltConfiguration'
),

und zusätzlich habe ich eine typoscript-abfrage:


[globalVar = GP:tx_somethingarticles_categorydetail|articleCategory > 0]
config.defaultGetVars {
    tx_somethingarticles_categorydetail.action = showByArticleCategory
    tx_somethingarticles_categorydetail.controller = Article
}
[global]

So klappts dann auch.

Schreibe einen Kommentar

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert

Diese Website verwendet Akismet, um Spam zu reduzieren. Erfahre mehr darüber, wie deine Kommentardaten verarbeitet werden.