This snippet will give you the IsNullOrEmpty function for PHP.

Sample PHP

function IsNullOrEmpty($input){
    return (!isset($input) || trim($input)==='');
}

2 thought on “IsNullOrEmpty function for PHP”

Leave a Reply