protected function generateLink($url, array $conf = null, $disableMP = false)
    {
        if ($conf === null) {
            $conf = array();
        }

        $mpOldConfValue = $GLOBALS['TSFE']->config['config']['MP_disableTypolinkClosestMPvalue'];
        if ($disableMP === true) {
            // Disable MP usage in typolink - link to the real page instead
            $GLOBALS['TSFE']->config['config']['MP_disableTypolinkClosestMPvalue'] = 1;
        }

        $conf['parameter'] = $url;

        $ret = $this->cObj->typoLink_URL($conf);
        // maybe baseUrlWrap is better? but breaks with realurl currently?
        $ret = GeneralUtility::fullUrl($ret);

        if ($disableMP === true) {
            // Restore old MP linking configuration
            $GLOBALS['TSFE']->config['config']['MP_disableTypolinkClosestMPvalue'] = $mpOldConfValue;
        }

        return $ret;
    }