• Resolved Patabugen

    (@patabugen)


    You’re using wp_is_mobile() to decide how to render content (e.g. the “share bar” and the “whatsapp” icon) – however this isn’t compatible with caching and means the WhatsApp button isn’t available on desktop even when the app is installed and the button would otherwise work.

    Could we have a way to disable these checks, or (preferably) move the device-specific styling to CSS so it can be more relevant, cached and we can tweak/override it?

    Workaround
    As a workaround for anybody who wishes to use this plugin and also use caching, this mu-plugin may help (but beware! It overrides _all_ frontend calls, not just SSBA ones).

    You can see the workaround here:
    https://gist.github.com/Patabugen/7f88cdcc42b9e0fbd9ab8062404f33d5

Viewing 1 replies (of 1 total)
  • Plugin Contributor ShareThis

    (@sharethis)

    Hello @patabugen,

    Thank you for taking the time to share this with us, we apologize for any inconvenience it might cause.

    We have already forwarded this to the appropriate team so they can take it into consideration for upcoming updates and make the plugin more flexible on these matters.

    Kind regards.

Viewing 1 replies (of 1 total)

The topic ‘Disable wp_is_mobile() checks’ is closed to new replies.