sudo code if ($debug == "true") { &debugit; # call the routine } or if ($debug == "true") { ** do all the debug code here and/or carry on ** }