WordPress.org

Ready to get started?Download WordPress

Forums

Pinterest "Pin It" Button
[resolved] Mixed content warning and plugin is blocked with HTTPS (3 posts)

  1. danielj@dtdo.net
    Member
    Posted 1 year ago #

    Is there a better option than what I did to fix this, so I don't have to remember to do this manually whenever the plugin is updated?

    I had to edit 2 lines in the code to make this work with https without getting the mixed content warning and no pinning:

    js/pin-it-button-user-selects-image.js:
    e.setAttribute('src','https://assets.pinterest.com/js/pinmarklet.js?r=' + Math.random()*99999999);

    and

    $link_href = 'https://pinterest.com/pin/create/button/?url=' . rawurlencode( $post_url ) . '&media=' . rawurlencode( $image_url ) . '&description='. rawurlencode( $description );

    http://wordpress.org/plugins/pinterest-pin-it-button/

  2. Phil Derksen
    Member
    Plugin Author

    Posted 1 year ago #

    In the next version of the plugin I'll be doing using a protocol-less URL structure as output by the official Pinterest widget builder, so you shouldn't get any warnings either way.

    $link_href = '//pinterest.com/pin/create/button/?url=' ...

    Also in the next update, the pin-it-button-user-selects-image.js file will go away completely as Pinterest has more recently added "user selects" functionality into their embed code as well.

  3. danielj@dtdo.net
    Member
    Posted 1 year ago #

    Wow. Now that's impressive customer service! Thank you :-)

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.