как удалить повторяющиеся косые черты с расширением realurl в typo3

Я использую расширение realurl, чтобы минимизировать свои URL-адреса, мне удалось удалить два элемента из URL-адреса, это было так: / blog / blog / artikel / news / detail / News /, а теперь это так / blog / artikel / Новости///. Вы можете видеть, что в конце есть лишние косые черты. я хочу избавиться от них. заранее спасибо, это мой файл конфигурации realurl

<?php
/**
 *
 * dix_UrlTool default realurl configuration
 * based on realurl-configuration of news.typo3.org
 *  http://news.typo3.org/about/realurl-configuration/
 *
 */

$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl'] = array ( 
    '_DEFAULT' => array (
        'init' => array (
            'enableCHashCache' => '1',
            'appendMissingSlash' => 'ifNotFile',
            'enableUrlDecodeCache' => '1',
            'enableUrlEncodeCache' => '1',
            'emptyUrlReturnValue' => '/',
        ),
        'redirects' => array (
//          'de/aerzte.html' => '/?id=51&L=3',
        'support.html' => 'go/support-active'
        ),
        'preVars' => array (
            '0' => array (
                'GETvar' => 'no_cache',
                'valueMap' => array (
                    'nc' => '1',
                ),
                'noMatch' => 'bypass'
            ),
            '1' => array (
                'GETvar' => 'L',
                'valueMap' => array (
                    'de' => '3',
                    'en' => '0',
                    'fr' => '6',
//                    '_DEFAULT' => '0',
                ),
                'noMatch' => 'bypass',
            ),            
        ),
        'pagePath' => array (
            'type' => 'user',
            'userFunc' => 'EXT:realurl/class.tx_realurl_advanced.php:&tx_realurl_advanced->main',
            'spaceCharacter' => '-',
            'languageGetVar' => 'L',
            'expireDays' => '7',
            'rootpage_id' => 3,
        ),
        'fixedPostVars' => array (
        ),
        'postVarSets' => array (

            '_DEFAULT' => array (

        // EXT:news start
        'news' => array(
                array(
                        'GETvar' => 'tx_news_pi1[action]',
                ),
                array(
                        'GETvar' => 'tx_news_pi1[controller]',
                ),
                array(
                        'GETvar' => 'tx_news_pi1[news]',
                        'lookUpTable' => array(
                                'table' => 'tx_news_domain_model_news',
                                'id_field' => 'uid',
                                'alias_field' => 'title',
                                'addWhereClause' => ' AND NOT deleted',
                                'useUniqueCache' => 1,
                                'useUniqueCache_conf' => array(
                                        'strtolower' => 1,
                                        'spaceCharacter' => '-',
                                ),
                                'languageGetVar' => 'L',
                                'languageExceptionUids' => '',
                                'languageField' => 'sys_language_uid',
                                'transOrigPointerField' => 'l10n_parent',
                                'autoUpdate' => 1,
                                'expireDays' => 180,
                        ),
                ),
        ),
        // EXT:news end                


            ),
        ),
        'fileName' => array (
//
// if you don't want .html-URLs set the following to "false" (e.g. 'defaultToHTMLsuffixOnPrev' => false,)
// then you get http://www.yourdomain.com/imprint/ instead of http://www.yourdomain.com/imprint.html
//
            'defaultToHTMLsuffixOnPrev' => false,
            'index' => array (
                'rss.xml' => array (
                    'keyValues' => array (
                        'type' => '100',
                    ),
                ),
                'rss091.xml' => array (
                    'keyValues' => array (
                        'type' => '101',
                    ),
                ),
                'rdf.xml' => array (
                    'keyValues' => array (
                        'type' => '102',
                    ),
                ),
                'atom.xml' => array (
                    'keyValues' => array (
                        'type' => '103',
                    ),
                ),
            ),
        ),
    ),

); 


$domains = array(
    '_DEFAULT' => '3',
);
foreach ($domains as $domain=>$pid) {
    $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl'][$domain] = $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl']['_DEFAULT'];
    $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl'][$domain]['pagePath']['rootpage_id'] = $pid;
}
//$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl']['www.***.com']['pagePath']['rootpage_id'] = 3;
?> 

person Oday Banihani    schedule 09.01.2018    source источник
comment
укажите свою версию realurl и файл конфигурации realurl. Кроме этого, я полагаю, вы упустили 'noMatch' => 'bypass',   -  person Bernd Wilke πφ    schedule 09.01.2018
comment
пожалуйста, проверьте, что я только что добавил код   -  person Oday Banihani    schedule 09.01.2018


Ответы (1)


попробуйте добавить 'noMatch' => 'bypass' в свой postvarSets:

:
'postVarSets' => array (
  '_DEFAULT' => array (
    // EXT:news start
    'news' => array(
            array(
                    'GETvar' => 'tx_news_pi1[action]',
                    'noMatch' => 'bypass'
            ),
            array(
                    'GETvar' => 'tx_news_pi1[controller]',
                    'noMatch' => 'bypass'
            ),
            array(
                    'GETvar' => 'tx_news_pi1[news]',
                    'noMatch' => 'bypass',
                    'lookUpTable' => array(
                           :
person Bernd Wilke πφ    schedule 09.01.2018