fixed php errors. links not working though