Support » Plugin: Mobile Device Detection by 51Degrees » Force desktop site

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author 51Degrees

    (@51degrees)

    Hi, Thanks for the support.

    The switcher can be disabled by setting a session variable called NO_SWITCH to true:

    $_SESSION['NO_SWITCH'] = TRUE; // no switching will occur

    I hope this is useful to you. We’d love to hear any feedback that could be used to improve the plugin.

    Thanks,
    Tom

    mrusselr

    (@mrusselr)

    Hi, sorry I know this is resolved, but I’m having the same issue. The $_SESSION[‘NO_SWITCH’] = TRUE; does not seem to be working and the site is still looping back to the mobile URL.

    Where is the best place to put $_SESSION[‘NO_SWITCH’] = TRUE; in the code to stop a redirect if you want to view the full site.

    Thanks.

    Plugin Author 51Degrees

    (@51degrees)

    WordPress code (and therefore 51Degrees code) runs before the page code loads, so there’s a good chance that a redirection has already been scheduled before your switch is set. After your switch is set try redirecting to the page to you desktop site again. You can see a working implementation in the Wave theme bundles with the plugin.

    Thanks,
    Tom

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Force desktop site’ is closed to new replies.