• Resolved freischwimmen

    (@freischwimmen)


    Hi, i added the plugin and i’m using it with with manual inserts in my templates, all is working fine on regular single posts , but not on single event entries that were added from within “The Events Calendar”, i assume those are custom post type entries…

    The Mashshare CSS and JS is not loaded on those posts and therefore sharing does not work. Should the Mashshare plugin work with custom post types as it is now?

    All worked fine before the major upgrade to Version 2.0.4

    The Events Calendar Plugin i am referring to is this one: https://wordpress.org/plugins/the-events-calendar/

    https://wordpress.org/plugins/mashsharer/

Viewing 13 replies - 1 through 13 (of 13 total)
  • Thread Starter freischwimmen

    (@freischwimmen)

    The custom post type i mentioned above is called tribe_events btw…

    Hello freischwimmen,

    i will create a option for custom post types so you can tell Mashshare to show the share buttons on this specific ones.

    I changed this behavior because i do not want to have Mashshare loading js and css file on pages where the Mashshare buttons are not used.

    If you know a better way how to check if a specific shortcode is running please let me know. I ll dig more into this!

    Thread Starter freischwimmen

    (@freischwimmen)

    Thanks a lot for the quick answer René, if you could add that functionality for custom post types that would be great! I understand why you changed it in the first place, makes sense.

    Thread Starter freischwimmen

    (@freischwimmen)

    Hi René, i installed the latest update but sharing still doesn’t work on custom post type articles, should this work after the latest update or did you not manage to adress this yet?

    Thanks a lot in advance!

    Please try a shortcode. This should work, isnt it?

    Thread Starter freischwimmen

    (@freischwimmen)

    Shortcode use is not really applicable in my case, i need to use the manual insert via <?php mashshare(); ?> – that one does unfortunately not work on custom post type articles yet.

    Thread Starter freischwimmen

    (@freischwimmen)

    I just checked because i was interested – all works fine when using the shortcode inside the post editor. Just so you know…

    Thread Starter freischwimmen

    (@freischwimmen)

    Just tried this in my template which didnt work either unfortunately: <?php echo do_shortcode(‘[mashshare]’); ?>

    Please put this in line 474 in /includes/template-functions.php

    if(has_action('mashshare')) {
                return true;
           }
           if(has_action('mashsharer')) {
                return true;
           }

    directly after:

    if( has_shortcode( $post->post_content, 'mashshare' ) ) {
                return true;
            }

    If it works, i put this code in the next update.

    Thread Starter freischwimmen

    (@freischwimmen)

    Works like a charm. Thank you very much Rene, the support on this plugin is second to none. Great Job!

    Glad to hear. Thank you!

    I had the same problem and your solution worked for me as well, Rene. Many thanks.

    Great jamiedesylva:-)

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘Sharing not working with Custom Post Types’ is closed to new replies.