fix bug with names like O'Connor

a bug in PHP caused names with apostrophes to trim string. Names like
"O'Connor" became "O". This is fixed now