<?php



$phrase  = "tablaNueva";

foreach (range('A', 'Z') as $letra) {
    $mayusculas[]= $letra;
}

foreach (range('a', 'z') as $letra) {
    $minuculas[]= "_".$letra;
}



$salida = str_replace($mayusculas, $minuculas, $phrase);
echo $salida;
?>