[TYPO3-ttnews] add extra parameter in news link

Francesc Juliana sad at sdf.com
Tue Apr 16 14:11:55 CEST 2013


I have investigated how to do it.
I have been able to do it by code.
I have added parameter Type=1 . So the example adds the parameter &type=1 on
each new.
Edit class.tx_ttnews.php which is in folder (\typo3conf\ext\tt_news\pi)
search these lines:

if ($this->conf['useHRDates'] && $this->conf['useHRDatesSingle']) {
   $this->piVars['year'] = $tmpY;
   $this->piVars['month'] = $tmpM;
   $this->piVars['day'] = $tmpD;
  }

Just below paste the following code:

foreach ($linkWrap as &$valor){
   $valor=str_replace("\" title=\"","&type=1\" title=\"",$valor );
  }

Remember to replace Type=1 for your parameter and value.
I hope it helps.

Regards

Francesc




"Francesc Juliana" <sad at sdf.com> escribió en el mensaje 
news:mailman.1.1365587064.4970.typo3-project-tt-news at lists.typo3.org...
> Hello everyone:
>
> I would like to add an extra parameter to every news link.
> I have tried this code in template but I don't get the desired result.
>
> plugin.tt_news {
>   displayList{
>
>      typolink {
>           additionalParams.wrap= |&type=1
>      }
>   }
> }
>
> Anyone knows how can Iadd an extra parameter to every news link?
>
> Thanks in advance.
>
> Francesc
> 




More information about the TYPO3-project-tt-news mailing list