I just installed NOOBS onto the SD card but I have just messed it up, it wasn't right for me anyway since I needed php5, and the latest NOOBS comes with php7. How can I install NOOBS so that I can install php5?
NOOBS will only install the latest Raspbian, if you need an obsolete version you will need to install Raspbian, which you can find on https://downloads.raspberrypi.org/raspbian/images/
You might get away with an old NOOBS from https://downloads.raspberrypi.org/NOOBS/archive/
Mind you PHP7 has been the standard release on most distributions for 2 years; it is only Debian which has not changed until recently.