Project

General

Profile

Bug #21396 ยป 12389.patch

Administrator Admin, 2009-10-29 09:41

View differences:

t3lib/class.t3lib_softrefproc.php (working copy)
$finalTagParts['LINK_TYPE'] = 'mailto';
$finalTagParts['url'] = trim($link_param);
} elseif ($this->isLinkhandlerValue($link_param)) {
// Check for link-handler keyword:
list($linkHandlerKeyword, $linkHandlerValue) = explode(':',trim($link_param), 2);
if ($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_softrefproc.php']['typolinkLinkHandler'][$linkHandlerKeyword] && strcmp($linkHandlerValue, '')) {
$linkHandlerObj = t3lib_div::getUserObj($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_softrefproc.php']['typolinkLinkHandler'][$linkHandlerKeyword]);
if( $linkHandlerObj instanceof softref_typolinkLinkHandlerHook ) {
$linkHandlerObj->getTypoLinkParts($finalTagParts, $link_param, $this);
}
}
} else {
$isLocalFile = 0;
$fileChar = intval(strpos($link_param, '/'));
......
}
/**
* Inndicate that the given $linkParam is a value from a registered linkhandler.
*
* @param string $linkParam Contains the value of the href attribute.
*
* @return boolean
*
* @author Michael Klapper <michael.klapper@aoemedia.de>
*/
protected function isLinkhandlerValue($linkParam) {
list ($linkHandlerKeyword, , ) = explode(':', $linkParam);
return array_key_exists($linkHandlerKeyword, $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['tslib/class.tslib_content.php']['typolinkLinkHandler']);
}
/**
* Recompile a TypoLink value from the array of properties made with getTypoLinkParts() into an elements array
*
* @param array TypoLink properties
......
} else return $content;
} else return $content;
break;
case 'linkhandler':
// Rebuild linkhandler reference
list($linkHandlerKeyword, $linkHandlerValue) = explode(':',trim($content), 2);
if ($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_softrefproc.php']['typolinkLinkHandler'][$linkHandlerKeyword] && strcmp($linkHandlerValue, '')) {
$linkHandlerObj = t3lib_div::getUserObj($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_softrefproc.php']['typolinkLinkHandler'][$linkHandlerKeyword]);
if( $linkHandlerObj instanceof softref_typolinkLinkHandlerHook ) {
$linkHandlerObj->setTypoLinkPartsElement($tokenID, $content, $elements, $idx, $this);
}
}
break;
case 'page':
// Rebuild page reference typolink part:
$content = '';
    (1-1/1)