Roman Lyashov committed eab4407

fixed bug, updated version and README

  • Participants
  • Parent commits ac9d95f

Comments (0)

Files changed (3)

+If you want to distinguish tablet devices from phones, then set MOBI_DETECT_TABLET = True and use request.tablet attribute
+{% if not or request.tablet %}
+	<p>This section enabled only for descktop and tablets</p>
+{% endif %}
 Using the mobi.MobileRedirectMiddleware Middleware
 This middleware will scan all incoming requests to see if it is a mobile device, if so it will redirect the request to a different URL. This is good if you want to force all mobile traffic to a mobile only version of your site.


     # it wasn't in the cache, get it from the file, then store in the cache
     with open(os.path.join(os.path.dirname(__file__), file_name)) as f:
-        ss = f.readlines()
+        ss =
     agents = [s.strip() for s in ss if s and not s.startswith('#')]
     # store to the cache
-    version='0.1.6',
+    version='0.1.7',
     description='Django middleware and view decorator to detect phones and small-screen devices',
     maintainer='Ken Cochrane',