Opened 18 years ago
Closed 17 years ago
#2086 closed defect (fixed)
Hack in admin's base.css generates 404 to non existing 'null' file.
Reported by: | rudolphfroger [-at-] gmail [-dot-] com | Owned by: | nobody |
---|---|---|---|
Component: | contrib.admin | Version: | |
Severity: | minor | Keywords: | |
Cc: | sam@… | Triage Stage: | Accepted |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | yes |
Easy pickings: | no | UI/UX: | no |
Description
I can see lot's off 404 errors in my apache logs because django/contrib/admin/media/css/base.css has this:
@import "null?\"\{";
The error in the log is like this:
[Mon Jun 05 00:15:28 2006] [error] [client 192.168.1.1] File does not exist: /home/someuser/django/trunk/django/contrib/admin/media/css/null, referer: http://media.example.com/admin/css/base.css
I know an more official way to give IE5 a special treatment in HTML, example:
<!--[if lte IE 5.0000]> <link rel="stylesheet" type="text/css" href="http://media.example.com/admin/css/ie5.css" /> <![endif]-->
But I don't know if something like this is usable in this case. Anyway IMHO it's just a minor bug so only solve it when all major bugs for a release are fixed.
Change History (11)
comment:1 by , 18 years ago
Severity: | normal → minor |
---|
comment:2 by , 18 years ago
Owner: | changed from | to
---|
comment:3 by , 18 years ago
comment:4 by , 18 years ago
Triage Stage: | Unreviewed → Accepted |
---|
comment:5 by , 18 years ago
Cc: | added |
---|
comment:6 by , 18 years ago
Wouldn't the simplest solution be just to include a empty file called "null" in the admin's css directory? From my understanding of the hack, it won't cause any change in function, and will stop the webserver generating misleading 404 errors.
comment:8 by , 17 years ago
I wanna know how to hack.. I want someone to give me admin login. i mean username and password for admin. i know .. 'or='
comment:9 by , 17 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:10 by , 17 years ago
Patch needs improvement: | set |
---|---|
Resolution: | fixed |
Status: | closed → reopened |
The same error message
File does not exist: /home/someuser/example/www/media/css/null, referer: http://www.example.com/admin/
still appears in the logs.
Probably because base.css tries to import 'null', not 'null.css'.
comment:11 by , 17 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
As a rule, I'd prefer to handle all the CSS hacks/import filters in the CSS files and leave only one stylesheet link per page in the HTML. So far, this is the only way I know of to hide all the imported CSS from IE5 (which is what this rule does). Seeing that it creates unnecessary 404s, I'll see if I can find another method of hiding CSS from IE5. Suggestions welcome!