Zum Inhalt springen

cObj->typolink Probleme mit 'additionalParams'

Erstellt am 30. März 2008 · 2 Antworten · letzte Antwort am 30. März 2008

Tags: Frage

pesto ·

Ich übergebe einem Link mit $urlParameters Parameter für eine fremde Extension. Wenn ich den Link mit typolink() generiere, funktioniert das ohne Probleme. Ich brauche aber eine andere Ziel-Id und nehme deswegen getTypoLink(). Im Quelltext erscheinen korrekt die $urlParameter, aber sie werden nicht von der Extension übernommen. Woran könnte das liegen? #paralyzed#

einpraegsam.​net ·
pesto schrieb

Im Quelltext erscheinen korrekt die $urlParameter, aber sie werden nicht von der Extension übernommen. Woran könnte das liegen? #paralyzed#

Poste doch einfach mal einen solchen Link...

pesto ·

Also, zuerst:

$this->local_cObj = t3lib_div::makeInstance("tslib_cObj");
$this->local_cObj->setCurrentVal($GLOBALS["TSFE"]->id);
$this->typolink_conf = $this->conf["typolink."];
$this->typolink_conf["parameter."]["current"] = 1;
$this->typolink_conf["additionalParams"] = $this->cObj->stdWrap($this->typolink_conf["additionalParams"], $this->typolink_conf["additionalParams."]);
unset($this->typolink_conf["additionalParams."]);

$this->allowCaching = $this->conf["allowCaching"]?1:0;
if (!$this->allowCaching) {
    $GLOBALS["TSFE"]->set_no_cache();
}

$temp_conf = $this->typolink_conf;
$temp_conf["additionalParams"] .= "&tx_pestosensor_pi1[showUid]=$sensorIds[$i]&tx_pestonotice_pi1[showUid]=$sensorIds[$i]";

$temp_conf["useCacheHash"] = $this->allowCaching;
$temp_conf["no_cache"] = !$this->allowCaching;

Dann der Link, von dem die $urlParameter nicht übernommen werden:

$the_link = $this->local_cObj->getTypoLink($link,$seitenIds[$i],$temp_conf,'');

So funktionierts:

$the_link = $this->local_cObj->typolink($link,$temp_conf);