ThemeShaper Forums » Thematic


add script to header

(4 posts)
  • Started 12 years ago by jwerre
  • Latest reply from helgatheviking
  • This topic is resolved
  1. how do I add a script tag to the header, or any other line of code for that patter.

    Posted 12 years ago #
  2. You mean a java / jQuery / whatever script?

    Add the following code to your child theme's functions.php:

    function my_script() {?>
      <script> whatever needs to be here </script>
    <?php }
    add_action('wp_head', 'my_script');



    Posted 12 years ago #
  3. Thanks! two years later this is still helping.

    Posted 10 years ago #
  4. this might also be of help to you

    Posted 10 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.