canha42 / pinterest-pin-it

Pinterest Pin It Button For Images - WordPress plugin
8 stars 9 forks source link

Code causes multiple HTML validation errors #27

Closed docevans closed 10 years ago

docevans commented 11 years ago

http://www.firsttech.com/?page_id=27

It doesn't like the ampersand between Url and image address (right before the word media): span class="xc_pin" onclick="pin_this(event, 'http://pinterest.com/pin/create/button/?url=http://www.firsttech.com/?page_id=2723&media=wp-content/uploads/2010/10/facetofaceSEMINARS.png&description=Free Seminar Schedule')"

It also errors on the ampersand before the word description.

chvillanuevap commented 11 years ago

In ppibfi_pinterest.php, you need to change:

            <span class="xc_pin" onclick="pin_this(event, \''.
            $pinterest_base_url.
            '?url='.esc_url($post_url).
            '&media=%2$s.%3$s'.'&description='.$post_title.'\')">
            </span>

To:

            <span class="xc_pin" onclick="pin_this(event, \''.
            $pinterest_base_url.
            '?url='.esc_url($post_url).
            '&amp;media=%2$s.%3$s'.'&amp;description='.$post_title.'\')">
            </span>
canha42 commented 10 years ago

Thanks @chvillanuevap - will be added to 1.1 and tested!

canha42 commented 10 years ago

Tested and running. Available in version 1.1