Jump to content

[SOLVED] PS 1.7.4 - How opening the mobile classic theme on the tablet ?


ba609

Recommended Posts

Try override function on class Context

public function getDevice()
    {
        static $device = null;

        if ($device === null) {
            if ($this->isTablet()) {
                //$device = Context::DEVICE_TABLET;
 				$device = Context::DEVICE_MOBILE;
            } elseif ($this->isMobile()) {
                $device = Context::DEVICE_MOBILE;
            } else {
                $device = Context::DEVICE_COMPUTER;
            }
        }

        return $device;
    }

 

Link to comment
Share on other sites

Quote

Try override function on class Context 


public function getDevice()
    {
        static $device = null;

        if ($device === null) {
            if ($this->isTablet()) {
                //$device = Context::DEVICE_TABLET;
 				$device = Context::DEVICE_MOBILE;
            } elseif ($this->isMobile()) {
                $device = Context::DEVICE_MOBILE;
            } else {
                $device = Context::DEVICE_COMPUTER;
            }
        }

        return $device;
    }

 

Hi phinq1910,

file to edit, .....prestashop/classes/Context.php

ThX

Edited by ba609 (see edit history)
Link to comment
Share on other sites

  • ba609 changed the title to [SOLVED] PS 1.7.4 - How opening the mobile classic theme on the tablet ?

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...