I am trying to insert a shortcode inside CSS file but i am unable to achieve it. Don't know where I am going wrong.
I am inserting below code inside my style.css file:
div#cuzd-dispatch-general-v {
display: <?php echo do_shortcode('[dispatch_date_hide]'); ?> ;
}
OUTPUT:
div#cuzd-dispatch-general-v {
display: <?php echo do_shortcode('[dispatch_date_hide]');
}
Output as Image: http://oi61.tinypic.com/2uiyd4x.jpg
add this code in your header.php inside <style> </style>
div#cuzd-dispatch-general-v {
display: <?php echo do_shortcode('[dispatch_date_hide]'); ?> ;
}
PHP code cannot be interpreted inside a .css file so your php code will be showen as a plain text, add the part of your code in the style tag of your php file.