chenhuanle / html5rocks

Automatically exported from code.google.com/p/html5rocks
0 stars 0 forks source link

Server should redirect if missing trailing '/' when servering index.html #754

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
When you go to  /en/tutorials/doodles/lem (without the trailing slash)

It tries to load /en/tutorials/doodles/images/mouse-pointers/wip/hover-1.png
(note the missing /lem/)
and not the proper 
/en/tutorials/doodles/lem/images/mouse-pointers/wip/hover-1.png

and so on for other images and scripts.
===

Per article solution:
Putting a proper <base> in the file could help too. If I do this as the first 
entry in <head> in the Lem article,
<base href='/en/tutorials/doodles/lem/'>

Original issue reported on code.google.com by ericbide...@html5rocks.com on 23 Dec 2011 at 4:48

GoogleCodeExporter commented 9 years ago
We should fix this at the server level, rather than using <base>. This is only 
an issue with
article that contain static content in their subdirectories. It has to do with 
the crazy logic
we're using for i18n.

Original comment by ericbide...@html5rocks.com on 23 Dec 2011 at 4:50

GoogleCodeExporter commented 9 years ago
http://code.google.com/p/html5rocks/source/detail?r=646b926b1196b44a450b3f66714c
ca7778766cea

Original comment by ericbide...@html5rocks.com on 10 Feb 2012 at 11:25