Php String Manipulation Class