Adds a while snippet for PHP