You will need to maintain all of the server side code that is on the page including the require once lines that include the necessary files. Along with this you also need to keep the js references intact on the page including the spry code that is toward the bottom of the page. What happens when you try to test the page out in it's default state unaltered?