Head & Footer Code

Easy add site-wide and/or article specific custom code before the </head> or </body> by hooking to wp_head and wp_footer.

Let we say that you have been told to add some custom code (HTML, JavaScript or CSS style) to page’s <head> (like site verification code, custom styles, webfont link, etc), or just before </body> (like pixel tracking, analytics code, heatmap code, etc), but you are not programmer. Then you can use Head & Footer Code to do that!

Simply go to ToolsHead & Footer Code in your website admin dashboard, and insert custom code to HEAD or FOOTER section (depending what you have to do).

If you have to insert some custom code specific for individual article (post, page, custom post type), then you can use Article specific metabox while you editing post/page/custom post type. There you can also set should that specific code be appended to site-wide code defined on ToolsHead & Footer Code, or should be overwritten.

FAQ

Features

  • Set site-wide custom content for head page section (before the </head>)
  • Set site-wide custom content for footer page section (before the </body>)
  • Set article specific custom code for head page section (before the </head>)
  • Set article specific custom content for footer page section (before the </body>)
  • Choose priority of printed custom code to head/footer sections (lower number mean far from </head> and </body>, higher number means closer to </head> and </body>)
  • Choose which post types will have enabled article specific head/footer fields
  • Choose should article specific head/footer code be appended to site-wide code, or will replace site-wide code
  • Site-wide section located under Tools → Head & Footer Code
    If you have enabled WP_DEBUG constant in wp-config.php, you’ll see site-wide and article specific entries in page source code wrapped to comments.

General settings, including HEAD, FOOTER global code and priority, have been saved to WordPress option auhfc_settings. Each post/page/custom post type specific HEAD and FOOTER code have been saved to post meta _auhfc. On plugin uninstall these data is also deleted from database.

Excellent basic header / footer code insertion tool

Download

Just great

Screenshots

Head and Footer Code - Site-wide settings page
Head and Footer Code – Site-wide settings page

Head and Footer Code - Article specific metabox
Head and Footer Code – Article specific metabox

Head and Footer Code - Example of custom code inserted to HEAD section (site-wide with appended article specific)
Head and Footer Code – Example of custom code inserted to HEAD section (site-wide with appended article specific)

Head and Footer Code - Example of custom code inserted to FOOTER section (site-wide with appended article specific)
Head and Footer Code – Example of custom code inserted to FOOTER section (site-wide with appended article specific)

Head & Footer Code in Media

Support

If you need support for this plugin, please open topic on community forum.

And we appreciate your support

Spread voice about Head & Footer Code on social networks, rate and review on WordPress.org, feedback in comments below or

Leave a Reply

Your email address will not be published. Required fields are marked *