I want to add some inline styles to my html website. I have my css code in a style file called copy.css. (As a background, I can tell that I am doing this because I want to put a big portion of code inline, and also I want to be able to have different inline css depending on my URL page. So having separate css files makes it more neat and manageable). The code inside my css file copy.css is now only:
/* My inline styles */
So, the result I want to get in my html is:
<style>/* My inline styles */</style>
I DO NOT want to get this code into my html (because it is a href and not a true inline):
<link rel='stylesheet' id='copy-css' href='https://www.HIDDEN.se/wp-content/themes/guru/copy.css?ver=6.0' type='text/css' media='all' />
The above <link ... /> code is generated by this code in a php file:
<?php
function add_custom_css() {
wp_enqueue_style('copy', get_template_directory_uri() . '/copy.css');
}
add_action( 'wp_enqueue_scripts', 'add_custom_css' );
?>
I have also tried using wp_add_inline_style but can not figure it out...all I do is to fetch the href and not the content of copy.css.