• Resolved Adrian Toll

    (@adriantoll)


    @gamerz Hi Lester. One issue we’ve come across with the 3.0 update is that we pass <svg> tags for arrow icons through the next / prev options, which are now stripped due to the options being passed through wp_kses_post() on line 42 of core.php. Is that something that you’d be handle in an update – perhaps a filter / option that allows us to disable wp_kses_post()?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter Adrian Toll

    (@adriantoll)

    This looks like it might be an earlier change than 3.0, this is actually happening on 2.94.6 and seems to be fixed in 3.0 in fact, so I’ll close this.

    Plugin Author Lester Chan

    (@gamerz)

    Hmm core.php is no longer in 3.0. 3.0 is actually the fix instead of breaking it, you can refer to the SVG allowed tags https://github.com/lesterchan/wp-pagenavi/blob/master/includes/class-wp-pagenavi-options.php#L109

    You can overwrite it if you want. My guess there are some attributes that are not whitelisted instead of SVG breaking by itself.

    add_filter( 'wp_pagenavi_allowed_html', function ( $allowed ) {
    $allowed['lineargradient'] = array( 'id' => true, 'x1' => true, 'y1' => true, 'x2' => true, 'y2' => true );
    $allowed['stop'] = array( 'offset' => true, 'stop-color' => true, 'stop-opacity' => true );
    return $allowed;
    } );
    Thread Starter Adrian Toll

    (@adriantoll)

    @gamerz Thanks, you were right – updating to 3.0 fixed this.

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

You must be logged in to reply to this topic.