moved all <script> to footer.php