And now for the standard "installing PHP from scratch" tuturial, no website would be complete without it. In fact, when I did this last week I had to search around for ages for the various information, so here follows a step-by-step list that aims to save you the hassle. Lines starting with a # denote comments, everything else must be typed as it appears.
Before we continue, note the following: for the install to work properly you need to *do everything as root*. And in the order outlined below :-). Also, it is good practice to put all your downloaded files in a standard place, people generally use /usr/local/src/