Support

Account

Home Forums General Issues PHP as CSS with ACF field Reply To: PHP as CSS with ACF field

  • Really helpful
    Just a little edit: if you want to use an option page to control your “global” css values use this hook instead for the first add_action:

    add_action( ‘acf/options_page/save’, ‘acf_generate_options_css’, 20 );

    This is actually very nice because if I understand correctly the css is saved as a static css file and is only updated when the user edits the page that contains ACF fields to control its variables so the server doesn’t have to elaborate it every time it wants to load it.