Adding Google Analytics Code to PHP-Fusion Updated on March 11, 2022 by InMotion Hosting Contributor 0 Minutes, 49 Seconds to Read In this tutorial we will show you how to add a Google Analytics Tracking code to your PHP-Fusion Website. Google analytics allows you to view statistics regarding visitors to your website. How to Add a Google Analytics Code: In the root of your PHP-Fusion files, edit the footer.php file. It is located in: /themes/templates/footer.php Enter the code google provided in the footer.php file, and save it. The code should look something like this: <script type=”text/javascript”> var _gaq = _gaq || []; _gaq.push([‘_setAccount’, ‘UA-XXXXX-Y’]); _gaq.push([‘_trackPageview’]); (function() { var ga = document.createElement(‘script’); ga.type = ‘text/javascript’; ga.async = true; ga.src = (‘https:’ == document.location.protocol ? ‘https://ssl’ : ‘https://www’) + ‘.google-analytics.com/ga.js’; var s = document.getElementsByTagName(‘script’)[0]; s.parentNode.insertBefore(ga, s); })(); </script> Be sure to replace UA-XXXXX-Y with the actual code google provided you with. Congratulations, now you know how to add a Google Analytics code to your PHP-Fusion website! Share this Article IC InMotion Hosting Contributor Content Writer InMotion Hosting contributors are highly knowledgeable individuals who create relevant content on new trends and troubleshooting techniques to help you achieve your online goals! More Articles by InMotion Hosting Related Articles Installing an Addon in PHP-Fusion Using the Contact Form in PHP-Fusion Security Options in PHP-Fusion Restoring a database backup in PHP-Fusion PHP-Fusion Main Site Settings Overview Modifying the Footer in PHP-Fusion Modify the sub-footer in PHP-Fusion Modify the copyright footer in PHP-Fusion Managing Site Links in PHP-Fusion Managing Panels in PHP-Fusion