PHP version of STHC.