switch($algo) { case "algo": include $algo.".php"; break; //etc... default: include "algo.php"; break; }