function wfGrabWidget(&$parser, &$nt, &$ret, $ns) { global $wgCanonicalNamespaceNames; if (!$nt) { return true; } if ($ns == NS_WIDGET) { //remove the namespace and colon $nt = strtoupper(preg_replace('@' . $wgCanonicalNamespaceNames[$ns] . ':@', '', $nt)); //do it $ret = ArticleWidgets::GrabWidget($nt); } return true; }
function wfGrabWidget(&$parser, &$nt, &$ret) { $nt = strtoupper(preg_replace('@:@', '', $nt)); $ret = ArticleWidgets::GrabWidget($nt); return true; }