Title: Different Inline
Last modified: July 23, 2017

---

# Different Inline

 *  Resolved [ThemeAWESOME](https://wordpress.org/support/users/tsquez/)
 * (@tsquez)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/different-inline/)
 * I have started to add Kirki to my theme and I noticed something in the header
   that has me concerned. I noticed that there is an inline style generated for 
   each one of the elements I have added the output to:
 *     ```
       <style id='kirki-styles-theme_typography-inline-css' type='text/css'>
       body,h1,h2,h2,h4,h5,h6{font-family:"Source Sans Pro", Helvetica, Arial, sans-serif;font-weight:400;font-style:normal;text-transform:none;color:#3f3f3f;}
       </style>
       <link rel='stylesheet' id='kirki-styles-top_sidebar_width-css'  href='http://localhost/forge/wp-content/plugins/kirki/assets/css/kirki-styles.css' type='text/css' media='all' />
       <style id='kirki-styles-top_sidebar_width-inline-css' type='text/css'>
       .top-sidebar.grid-container{max-width:900px;}
       </style>
       <link rel='stylesheet' id='kirki-styles-inside_top_sidebar_width-css'  href='http://localhost/forge/wp-content/plugins/kirki/assets/css/kirki-styles.css' type='text/css' media='all' />
       <style id='kirki-styles-inside_top_sidebar_width-inline-css' type='text/css'>
       .inside-top-sidebar{max-width:800px;}
       </style>
       ```
   
 * Is this supposed to happen? Is inline css generated for each one? Why are they
   not grouped together under one `kirki-styles` sheet?…just curious.
 * Lovin’ the plugin by the way 😉

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

 *  Thread Starter [ThemeAWESOME](https://wordpress.org/support/users/tsquez/)
 * (@tsquez)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/different-inline/#post-9344062)
 * Sorry the title got cut off. It was supposed to say Different Inline Styles Being
   Generated for each Element?
 *  [Ari Stathopoulos](https://wordpress.org/support/users/aristath/)
 * (@aristath)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/different-inline/#post-9344193)
 * I can only think o 1 thing that would cause this, and that’s using a different
   config-ID for every control you create.
 * When you create a field in Kirki, the syntax looks something like this:
    `Kirki::
   add_field( $config_id, $args );` The `$config_id` argument is the same for ALL
   your fields, not different for each field. It is not the field-id, it is an id
   that helps Kirki understand what kind of options your fields will use as well
   as the capabilities required to edit those fields (for example `theme_mod` or`
   option` for option-type and `edit_theme_options` for capability).
 * So this is what your code should look like:
 *     ```
       Kirki::add_config( 'my_theme', array(
       	'capability'    => 'edit_theme_options',
       	'option_type'   => 'theme_mod',
       ) );
   
       Kirki::add_field( 'my_theme', $field_1_args );
       Kirki::add_field( 'my_theme', $field_2_args );
       Kirki::add_field( 'my_theme', $field_3_args );
       ```
   
 * Of course each field has its own args defined as an array, and the actual field-
   id is defined as the `settings` argument in there, but the important thing to
   notice above is that all fields in the above example use `my_theme` as the config-
   id, and that configuration is defined using `Kirki::add_config`.
 * You can read more about adding configurations on [https://aristath.github.io/kirki/docs/getting-started/config.html](https://aristath.github.io/kirki/docs/getting-started/config.html)
   and adding fields on [https://aristath.github.io/kirki/docs/getting-started/fields.html](https://aristath.github.io/kirki/docs/getting-started/fields.html)
    -  This reply was modified 8 years, 10 months ago by [Ari Stathopoulos](https://wordpress.org/support/users/aristath/).
 *  Thread Starter [ThemeAWESOME](https://wordpress.org/support/users/tsquez/)
 * (@tsquez)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/different-inline/#post-9344236)
 * AH HA! Got yah sir, yes that makes sense. made the change, now everything is 
   showing under one inline style declaration.
 * AWESOME!!! Thanks for the help and the awesome plugin. Keep up the good work.
 *  Thread Starter [ThemeAWESOME](https://wordpress.org/support/users/tsquez/)
 * (@tsquez)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/different-inline/#post-9344254)
 * Also I cannot say this enough “THIS IS ONE BADASS PLUGIN”… sorry I already gave
   you a review, so I thought I would just throw this in here.
 * SIMPLY BADASS!!!! 🙂
 *  [Ari Stathopoulos](https://wordpress.org/support/users/aristath/)
 * (@aristath)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/different-inline/#post-9344276)
 * I’m glad I could help! 🙂

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

The topic ‘Different Inline’ is closed to new replies.

 * ![](https://ps.w.org/kirki/assets/icon-256x256.jpg?rev=3518366)
 * [Kirki – Freeform Page Builder, Website Builder & Customizer](https://wordpress.org/plugins/kirki/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/kirki/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/kirki/)
 * [Active Topics](https://wordpress.org/support/plugin/kirki/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/kirki/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/kirki/reviews/)

 * 5 replies
 * 2 participants
 * Last reply from: [Ari Stathopoulos](https://wordpress.org/support/users/aristath/)
 * Last activity: [8 years, 10 months ago](https://wordpress.org/support/topic/different-inline/#post-9344276)
 * Status: resolved