plyed around a fair bit with php