Created commonfuncs.php