WordPress.org

Ready to get started?Download WordPress

Forums

Flattr
[resolved] Error in flattr button style introduced in 1.0? (4 posts)

  1. rolfkleef
    Member
    Posted 2 years ago #

    After I updated from 0.99.3 to 1.0.0, I see javascript buttons instead of image buttons: the option Button Type is ignored.

    I had a look at the changes in the code, and probably found the problem at line 484:

    -                switch (get_option(flattr_button_style)) {
    +                switch (empty($type) ? get_option(flattr_button_style) : $type) {

    Before looking at the setting of the option, it first checks whether $type is empty. But since it is set to 'Javascript' as default value if no parameter is given, it won't ever be empty.

    I don't have a fix that does use $type, but just reverted that change to get my site back to using the image button. It might take a little more effort to get the logic right with optionally overriding $type...

    http://wordpress.org/extend/plugins/flattr/

  2. rolfkleef
    Member
    Posted 2 years ago #

    oops, should have mentioned that I'm referring to the code for getButton() in flattr.php...

  3. VoxPelli
    Member
    Plugin Author

    Posted 2 years ago #

    Rather embarrassing bug :/ Fixed in 1.0.1 which is out now - thanks for pointing it out!

  4. rolfkleef
    Member
    Posted 2 years ago #

    thanks for the quick fix :-)

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags