finish version of php and ajax
first loop of sending data to the server