Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • WalterWhite
    Participant

    Hi,

    can the html generated from the WP Socializer Share icons be removed from the WordPress API endpoint?

    Hi there,

    Can you please share more details on “WordPress API endpoint” and where it is shown?

    Ideally the plugin inserts the share icons only above/below posts and pages.

    Thanks,
    Aakash

    WalterWhite
    Participant

    Hi Aakash,

    In the wordpress rest api (https://example.com/wp-json/wp/v2/pages), I can see the html share code on every page that the share was included.

    Also I’m using the plugin ‘the events calendar’, and the share code is showing in the events API description.

    Is there a way, the share code is not included in the WordPress API please

    Thanks in advance

    Hi Walter,

    This is weird. I’ll have a look at my test setup and see how this can be prevented. I’ll share an update in a couple of days.

    Thanks,
    Aakash

    WalterWhite
    Participant

    Thanks Aakash

    Hi Walter,

    Can you please make the change below in the plugin editor?

    1) Disable WP Socializer plugin.
    2) Go to plugins -> plugin editor -> select wp-socializer/core/location-rules.php

    3) At line no.142, paste the code below.

    		if (defined('REST_REQUEST') && REST_REQUEST) {
    			return 0;
    		}

    4) Save the changes and activate the plugin.

    I’ll ensure this is addressed in the next version of the plugin.

    Thanks,
    Aakash

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.

Subscribe for updates

Get updates on the WordPress plugins, tips and tricks to enhance your WordPress experience. No spam. View newsletter