add Observer Pattern - php