Title: Individual code per page
Last modified: June 20, 2019

---

# Individual code per page

 *  Resolved [robteee](https://wordpress.org/support/users/robteee/)
 * (@robteee)
 * [6 years, 11 months ago](https://wordpress.org/support/topic/individual-code-per-page/)
 * Hi Stefano,
 * Maybe I am overlooking this, but is this plugin capable of injecting code on 
   individual pages or posts?
 * This may be the same question as [https://wordpress.org/support/topic/is-it-possible-to-add-different-code-in-head-for-every-page/](https://wordpress.org/support/topic/is-it-possible-to-add-different-code-in-head-for-every-page/)
 * Thank you

Viewing 7 replies - 1 through 7 (of 7 total)

 *  [dannanelli](https://wordpress.org/support/users/dannanelli/)
 * (@dannanelli)
 * [6 years, 11 months ago](https://wordpress.org/support/topic/individual-code-per-page/#post-11668864)
 * This plugin is the best one I’ve found so far a I love it! But you are right,
   it would be awesome to be able to include or exclude certain pages and / or control
   individual pages. I don’t think it has this feature at the moment but would love
   it know if it’s in the roadmap! 🙂
 *  [thereznation](https://wordpress.org/support/users/thereznation/)
 * (@thereznation)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/individual-code-per-page/#post-11753696)
 * this plugin is a joke if you can’t do that. I am trying to find a plugin to put
   javascript code on one particular thank you page and i can’t find anywhere on
   the internet on how to do that. this is absurd
 *  [nikana2000](https://wordpress.org/support/users/nikana2000/)
 * (@nikana2000)
 * [6 years, 9 months ago](https://wordpress.org/support/topic/individual-code-per-page/#post-11854391)
 * [@thereznation](https://wordpress.org/support/users/thereznation/) I don’t know
   if you’ll have better luck than me, but there’s this option
 *     ```
       /* Describe what the code snippet does so you can remember later on */
       add_action('wp_head', 'your_function_name');
       function your_function_name(){
       if(is_single(73790)) {  ?>
       PASTE HEADER CODE HERE
       <?php  }
       };
       ```
   
 * from here: [https://kinsta.com/knowledgebase/add-code-wordpress-header-footer/](https://kinsta.com/knowledgebase/add-code-wordpress-header-footer/)
 *  Plugin Author [Stefano Lissa](https://wordpress.org/support/users/satollo/)
 * (@satollo)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/individual-code-per-page/#post-12307807)
 * A simple code can be added directly in header and footer (php is allowed)
    <?
   php if(is_single(73790)) { ?> PASTE HEADER CODE HERE <?php } ?>
 *  [jfbprivate](https://wordpress.org/support/users/jfbprivate/)
 * (@jfbprivate)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/individual-code-per-page/#post-12613351)
 * Is there a way (and I don’t mind a workaround) to inject HTML into the body (
   not the header or footer) of a specific page, too? I would like to add CSS classes
   to one particular page only. Integrating this feature would certainly add to 
   the value of the plugin. Many thanks
    -  This reply was modified 6 years, 2 months ago by [jfbprivate](https://wordpress.org/support/users/jfbprivate/).
 *  Plugin Author [Stefano Lissa](https://wordpress.org/support/users/satollo/)
 * (@satollo)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/individual-code-per-page/#post-12616343)
 * The code above explain how to do that. Anyway, having a single page where you
   need to add code, why not add it to that specific page directly?
 * WP classic editor and gutenberg both supports the JS code.
 * Stefano.
 *  [jfbprivate](https://wordpress.org/support/users/jfbprivate/)
 * (@jfbprivate)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/individual-code-per-page/#post-12617349)
 * Yeah I’ve had issues with those for some reasons which is why I came here. Anyway
   I’ve figured it out in the meantime. Thanks

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Individual code per page’ is closed to new replies.

 * ![](https://ps.w.org/header-footer/assets/icon-256x256.png?rev=3452717)
 * [Head, Footer and Post Injections](https://wordpress.org/plugins/header-footer/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/header-footer/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/header-footer/)
 * [Active Topics](https://wordpress.org/support/plugin/header-footer/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/header-footer/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/header-footer/reviews/)

## Tags

 * [code](https://wordpress.org/support/topic-tag/code/)
 * [head](https://wordpress.org/support/topic-tag/head/)
 * [noindex](https://wordpress.org/support/topic-tag/noindex/)

 * 7 replies
 * 2 participants
 * Last reply from: [jfbprivate](https://wordpress.org/support/users/jfbprivate/)
 * Last activity: [6 years, 2 months ago](https://wordpress.org/support/topic/individual-code-per-page/#post-12617349)
 * Status: resolved