1) && (SubStr($int_secs_string, 0, 1) == "0")) $int_secs_string = SubStr($int_secs_string, 1); //Form an integer result that is offset from this integer by the passed //value. $offset_time = bcadd($int_secs_string, (string)$offset_in); //Apply the floor and ceiling. if (bccomp($offset_time, "0") == -1) { //Result is below the Unix epoch. Apply floor. // return("UT00000000000000000000"); } else if (bccomp($offset_time, "99999999999") == 1) { //Result is above the max value that can be represented. Apply ceiling. // return("UT99999999999000000000"); } else { //Result is valid. Format the string and return. $offset_time = (string)$offset_time; // $offset_time = STRFUNC_pad_left_zero($offset_time, 11); return("UT" . $offset_time . "000000000"); } } // //-------------------------------------------------------------------------------- //Reformats an UTIME string to include dots at strategic places for more //human-friendly display. // function UTIME_dotted_display_string_a($utime_in) { if (! is_string($utime_in)) { //Don't know what this is ... it isn't an utime. Just send it back. return($utime_in); } else if (strlen($utime_in) != 22) { //This doesn't seem to be the right length for an utime. Give it back. return($utime_in); } else { //Seems right. return( SubStr($utime_in, 0, 2) . "." . SubStr($utime_in, 2, 11) . "." . SubStr($utime_in, 13, 9) ); } } // //-------------------------------------------------------------------------------- //End of $RCSfile: utimex.inc,v $. //-------------------------------------------------------------------------------- ?>