why not use json_encode for all values?