• Resolved aktionj33

    (@aktionj33)


    I am trying to conditionally load scrips and css based on the pages they are required. I am using wp_dequeue to do this. But it only works if the scrips and css are enqueued. Is there an easy way to do this in the code. I tried playing with it but though I was able to prevent it from loading by add wp_enqueue in wpsocialite.php, it broke the mouseover on load function for the pinterest button (even though the button still worked but it never switched from the sprite image to the button).

    Thoughts?

    http://wordpress.org/plugins/wpsocialite/

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Tom Morton

    (@tm3909)

    WPSocialite has to load extensions like Pinterest outside of the normal wpsocialite.js (look for extension.pinterest.js).

    I suspect that is the issue. Let me know if that helps!

    Thread Starter aktionj33

    (@aktionj33)

    Thanks for replying Tom,
    Yes Tom I am sure you are right.I did locate the script inside wpsocialite.php. Is there a way to modify that code to enqueue the script or does that break functionality somehow? It breaks it when I try to change it to load with wp_enqueue. Even though the sprite button still loads pinterest sharing even though the mouseover never takes place.

    Plugin Author Tom Morton

    (@tm3909)

    You will need to re-enqueue pinterest as well as wpsocialite.js

    So when you load wpsocialite.js, you need to also load extensions/extension.pinterest.js

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

The topic ‘How to wp_enqueue socialite.pinterest.js’ is closed to new replies.