Skip to main content

Django UserAgent Detect

Project description

Installation

pip install django-detect

Usage

# ####### Device、OS #######
# Windows
request.Windows
# Linux
request.Linux
# iMac/iPhone/iPad/iPod
request.iMac
request.iPhone
request.iPad
request.iPod
# PC
request.PC = request.Windows or request.Linux or request.iMac
# iOS
request.iOS = request.iPhone or request.iPad or request.iMac or request.iPod
# Android and Version
request.Android
request.Android.version

# ####### APP #######
# Weixin/Wechat and Version
request.weixin
request.weixin.version
request.wechat
request.wechat.version

Settings.py

# Use `MIDDLEWARE_CLASSES` prior to Django 1.10
MIDDLEWARE = (
    ...
    'detect.middleware.UserAgentDetectionMiddleware',
    ...
)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-detect-1.0.15.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

django_detect-1.0.15-py2.py3-none-any.whl (3.4 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file django-detect-1.0.15.tar.gz.

File metadata

  • Download URL: django-detect-1.0.15.tar.gz
  • Upload date:
  • Size: 3.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/18.5 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/2.7.10

File hashes

Hashes for django-detect-1.0.15.tar.gz
Algorithm Hash digest
SHA256 9dfc8492f8a557471100a76fb76bd0fcf3f5bfb599c157bc2d3009cac1e5c7ca
MD5 58e0c8cc21e14baf6a805964a5bea3af
BLAKE2b-256 5a7fc073dd060288c538e407c931144eafd4aef424b559556c41f65b16628854

See more details on using hashes here.

File details

Details for the file django_detect-1.0.15-py2.py3-none-any.whl.

File metadata

  • Download URL: django_detect-1.0.15-py2.py3-none-any.whl
  • Upload date:
  • Size: 3.4 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/18.5 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/2.7.10

File hashes

Hashes for django_detect-1.0.15-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 368865319198780bdac08bd22807411a6d971c7430c5ccae72bfa008c9f40be4
MD5 9205b12defcc7438347b17781af5d652
BLAKE2b-256 7dcb05526c2e3c1974e85d5a75aec48d1ef7014773e9c45f945a55b7ca833df8

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page