[TYPO3-dev] A hook in indexed_search - nonsense?

Tapio Markula tapio.markula at xetpoint.fi
Wed Aug 22 11:23:01 CEST 2007


Steffen Kamper kirjoitti:
> Hi Tapio,
> 
> best would be to make a proposal in BT

Endeed I got that working - because the hook itself is refence to the 
$this-variable it doesn't need as parameter &$this.

<?php

class user_indexed_search_conf {
    function initialize_postProc(){
#t3lib_div::debug($this->pObj); // I must add '->pObj'
#t3lib_div::debug($this->pObj->conf);
#t3lib_div::debug($this->pObj->piVars);

            // If "_sections" is set, this value overrides any existing 
value.
        if ($this->pObj->piVars['_sections']) 
$this->pObj->piVars['sections'] = &$this->pObj->piVars['_sections'];
        elseif($this->pObj->conf['sections'])        {
            $this->pObj->piVars['_sections'] = 
$this->pObj->conf['sections'];
            $this->pObj->piVars['sections'] = $this->pObj->conf['sections'];
        }
        return;
    }
}
?>

That does what I want. I want to set section information for normal search

I made a small plugin for a customer. He needed this in one branch:

plugin.tx_indexedsearch.sections=rl1_616




More information about the TYPO3-dev mailing list