while () { $url = $_; $response = 0; unless($response == 200) { yada yada yada yada.. } } #### if($response == 500) { goto next; } I also tried just next; and that didn't work.