Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'WSGIRequest' object has no attribute 'user_agent' #4

Closed
mav-erick opened this issue Jul 10, 2017 · 1 comment
Closed

'WSGIRequest' object has no attribute 'user_agent' #4

mav-erick opened this issue Jul 10, 2017 · 1 comment

Comments

@mav-erick
Copy link

mav-erick commented Jul 10, 2017

Error in django 1.11. Please help.

if request.user_agent.is_mobile:

@cvarelaruiz
Copy link

cvarelaruiz commented Dec 15, 2017

You need to ensure that Django User Agents is installed. Then you need to add it to the INSTALLED_APPS section in your django config file as well as the 'django_user_agents.middleware.UserAgentMiddleware' to the MIDDLEWARE section (or MIDDLEWARE_CLASSES depending on your version of django) .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants