Adding secure versions of the PHP scripts