PHP: handle undefined exception -
i have device sends data url, depending on situations 3 4 parameters received, when try data 4th parameter using
$a = $_get["xyz"];
in case when "xyz" not exist function
_get['xyz'];
returns undefined. tried using try catch , initialized $a empty string in catch part did not work either. how can undefined exception handled?
if(isset($_get["xyz"])) { $a = $_get["xyz"]; }
Comments
Post a Comment