mirror of
https://github.com/sjlongland/tornado-gallery.git
synced 2025-09-13 08:42:23 +10:00
server: Support photo.html
pseudo-page
Certain phone browsers (ahhem, ZTE!) ignore the `Content-Type` header and try to parse the URI to figure out what kind of page they're getting sent, and will choke if given a HTML file when the URI ends in `.jpg`.
This commit is contained in:
parent
8372935fe1
commit
43661fb8ba
@ -229,7 +229,7 @@ class GalleryApp(Application):
|
||||
PhotoHandler),
|
||||
(r"/([a-zA-Z0-9_\-]+)/([a-zA-Z0-9_\-]+\.[a-zA-Z]+)/thumb.jpg",
|
||||
ThumbnailHandler),
|
||||
(r"/([a-zA-Z0-9_\-]+)/([a-zA-Z0-9_\-]+\.[a-zA-Z]+)(?:\.html)?",
|
||||
(r"/([a-zA-Z0-9_\-]+)/([a-zA-Z0-9_\-]+\.[a-zA-Z]+)(?:/?[a-z]*\.html)?",
|
||||
PhotoPageHandler),
|
||||
(r"/([a-zA-Z0-9_\-]+)/?", GalleryHandler),
|
||||
(r"/", RootHandler),
|
||||
|
Loading…
Reference in New Issue
Block a user