WordPress.org

Ready to get started?Download WordPress

Forums

AnythingSlider for WordPress
Removing style tag from inside BODY (1 post)

  1. dariodev
    Member
    Posted 2 years ago #

    I'm trying to remove <style> tags from output, because style tags should not be in body, and add them in the wp_head.
    Here is original piece of code:

    $output .="
    <style>
      #slider-{$id} { width: {$width}px; height: {$height}px; }
    </style>
    ";

    So I'm trying to hook following function to add style tag in wp_head, but problem is that variables $id and $width cannot be passed into the function.

    function add_slide_style() {
    	echo '<style>';
    	echo '#slider-{$id} { width: {$width}px; height: {$height}px; }';
    	echo '</style>';
    }

    Has anyone tried something like that?

    http://wordpress.org/extend/plugins/anythingslider-for-wordpress/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic