Worked on php functions