Automattic\Jetpack\Device_Detection
User_Agent_Info::get_desktop_platform()
Returns the platform for desktops
Метод класса: User_Agent_Info{}
Хуков нет.
Возвращает
Строку
.
Использование
$User_Agent_Info = new User_Agent_Info(); $User_Agent_Info->get_desktop_platform();
Код User_Agent_Info::get_desktop_platform() User Agent Info::get desktop platform WPSCache 1.12.4
public function get_desktop_platform() { $ua = $this->useragent; if ( empty( $ua ) ) { return false; } $platform = self::OTHER; if ( static::is_linux_desktop() ) { $platform = self::PLATFORM_DESKTOP_LINUX; } elseif ( static::is_mac_desktop() ) { $platform = self::PLATFORM_DESKTOP_MAC; } elseif ( static::is_windows_desktop() ) { $platform = self::PLATFORM_DESKTOP_WINDOWS; } elseif ( static::is_chrome_desktop() ) { $platform = self::PLATFORM_DESKTOP_CHROME; } return $platform; }