modified:   lib.php