if ($pageTitle == "manager_url") {
    $config = $modx->getConfig();
    $output = $config["manager_url"];
} else {
    $page = $modx->getObject('modResource', array("pagetitle" => $pageTitle));
    $output  = $modx->makeUrl($page->get('id'));
}
return $output;