Support » Plugin: WordPress Popular Posts » Wrong custom HTML after update

  • Resolved jbx

    (@jbx)



    I’ve just updated to Version 3.2.0, and something seems to be wrong in the output of the widget. I use the following custom HTML (which works fine on previous versions).

    <li>{thumb} <div class="wpp-title">{title}</div></li>

    Immediately after update, I am getting this when I do ‘View Source’ in my browser:

    & lt; li & gt; ...

    It seems that the HTML tags are being converted to HTML entities, with the < and > converted to & lt; and & gt; etc.

    (I added the spaces myself because this editor was converting them automatically)

    I rolled back to the previous version and it worked fine again.

    https://wordpress.org/plugins/wordpress-popular-posts/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Hector Cabrera

    (@hcabrera)

    Thanks for the report! I’ll look into it.

    Plugin Author Hector Cabrera

    (@hcabrera)

    Alright, here’s a quick & dirty fix for the time being:

    1. Go to Plugins > Editor and select WordPress Popular Posts from the drop down at the right.
    2. Find: $content = $this->__format_content($instance['markup']['post-html'], $data, $instance['rating']) . "\n"; and replace it with: $content = htmlspecialchars_decode( $this->__format_content($instance['markup']['post-html'], $data, $instance['rating']), ENT_QUOTES ). "\n";
    3. Hit the Update file button to save changes.

    Alternatively, you might just want to wait a few minutes while I upload the fix. I won’t be releasing version 3.2.1 though, so redownloading 3.2.0 should do the job.

    jbx

    (@jbx)

    Hi Hector,

    No worries, I will wait for your update.
    The production site is running fine with the older version.

    Thanks.

    Plugin Author Hector Cabrera

    (@hcabrera)

    Just uploaded the fix. Please redownload version 3.2.0 and let me know how it goes.

    jbx

    (@jbx)

    Worked perfectly.

    Cheers!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Wrong custom HTML after update’ is closed to new replies.