Quick and Dirty way to add code some Javascript to a footer

I every once and a while a client needs me to add some kind of Javascript code to the site. Most time it is a Google snippet or something for Facebook. It is always for tracking purposes. Just open functions.php and add this in the file.

function ar_add_facebook_snippet() { ?>


Obviously, change ar_add_facbook_snippet to something related to your project like yourproject_add_servicename_snippet.

Leave a Comment





This site uses Akismet to reduce spam. Learn how your comment data is processed.