fixing key close php 2