I have a boolean variable which I want to convert to a string
$res = true;
I need it the converted value to also be in the format "true" "false"
not "0" "1"
$converted_res = "true";
$converted_res = "false";
I've tried:
$converted_res = string($res);
$converted_res = String($res);
but it tells me string
and String
are not recognized functions. How do I convert this boolean to a string in the format "true" or "false" in php?