some fixes (php version differences)