add c and php function