M.. He estado intentando y buscando informacion, pero no entiendo, como usr el preg_replace_callback()
 
He hecho esto para probar 
 Código PHP:
    <?
require("./geshi/geshi.php");
function php($matches) {
    return geshi_highlight("php", $matches[0], "geshi/geshi/", true);
}
function BBC_Smileys ($string) {
    $string=nl2br($string);
 
   $texto = preg_replace_callback("/\[code\](.+)\[\/code\]/is", "php", $string);
   
   return $texto;
}
?>    
  Devuelve "php" en ves del codigo, ni siquiera si reemplazo   
 Código PHP:
    return geshi_highlight("php", $matches[0], "geshi/geshi/", true); 
    
  por   
 Código PHP:
    return $matches[0] 
    
  Entonces devuelve las mismas etiquetas 
Saludos