[TYPO3-english] Realurl - Scandinavian characters and SB portfolio

Tomasz Krawczyk tomkrawc at gmail.com
Thu Jul 14 00:22:01 CEST 2011


W dniu 2011-07-12 11:56, Jogvan Olsen pisze:
> Hi List
>
> I have a little problem for SB Portfolio. I have adapted the Realurl
> setup from the manual to site - and it works perfect except from one thing.
>
> The 'tag' ('GETvar' => 'tx_sbportfolio_pi1[tag]'):
>
> - The Scandinavian characters (ÆØÅæøå) are not converted to their ASCII
> equivalents
> - Spaces are not converted to space character '-'
> - Is not converted to lowercase.
>
> ex.
> My url look like this:
> http://my-domain.dk/eksempler/tag/Jubilæumsskrift 2010/
>
> I want them to look like this:
> http://my-domain.dk/eksempler/tag/jubilaeumsskrift-2010/
>
>
>
> All other parts of the url are converted to nice looking lowercase ASCII
> characters, with '-' as space-character.
>
> I have pasted my realurs setting below - Can anyone see what I am
> missing, and give me some advice?
>
>
> Thanks in advance
> Jogvan Olsen
>
>
> ?>
>

Hi

I think you can achieve your goals with userFunc. See realurl 
documentation. You have to write your own class for encoding and 
decoding tx_sbportfolio_pi1[tag] parameter.

Here is a part of one of my sites realurl configuration. In this case 
tx_drblob_pi1[sort] gets values "title:0" or "crdate:1" and it is 
converted by my class to: "by-title-asc" and "by-crdate-desc".

'postVarSets' => array(
	'_DEFAULT' => array(
		'sorting' => array(
			array(
				'GETvar' => 'tx_drblob_pi1[sort]',
				'userFunc' => 
'EXT:site_specific/class.tx_realurl_userfunc_drblob.php:&tx_realurl_userfunc_drblob->main',
			),
		),
	)
)

Result on the site http://dev.freshsite.pl/download.html in the table 
header.

-- 
regards
Tomek


More information about the TYPO3-english mailing list