moved code to open the door to PHP and updated documentation