Converting html to php, adding js