is_defined function for check constant available or not


function is_defined($constant) {
    $constant = strtoupper($constant);
    if (defined($constant) && constant($constant)) {
        return true;
    }
    return false;
}
Bhargav Bhuva PHP Developer

No comments: