Closed michaelrsweet closed 9 years ago
CUPS.org User: mike
Alex,
Does your mime.types file have the following rule for application/x-csource?
application/x-csource c cxx cpp cc C h hpp \ printable(0,1024) + ! css + \ (string(0,/*) string(0,//) string(0,#include) contains(0,1024,<0a>#include) \ string(0,#define) contains(0,1024,<0a>#define))
The "! css" part should prevent this rule from matching a .css file with C comments.
CUPS.org User: alexk
Yes, it does contain it, and I see ! css part there, but it doesn't help. I also tried to move the line "text/css css" higher than this one hoping it would be matched first, but it didn't help either.
CUPS.org User: mike
Still unable to reproduce on my end. All I can guess is that you have old MIME types files in /etc/cups or /usr/share/cups/mime that are causing the typing to be done incorrectly.
Hi
JFYI : I got this css-error after debian dist upgrade jessie --> stretch. Reason: very old mime.types in /etc/cups as Mike guessed above
Gruss, Juergen
Still present for me in Debian 9 and CUPS version 2.2.1-8+deb9u3. Manually removing mime.types
and mime.convs
files from /etc/cups
(like suggested in Debian Bug report logs - #792731) let the CUPS admin web interface use the CSS like expected (after a cupsd
restart) again.
Fixed it for me
# Remove files
rm /usr/share/cups/mime/mime.convs /usr/share/cups/mime/mime.types
rm /etc/cups/mime.convs /etc/cups/mime.types
# Get fresh files from github
wget -O /etc/cups/mime.types https://raw.githubusercontent.com/apple/cups/master/conf/mime.types
wget -O /etc/cups/mime.convs https://raw.githubusercontent.com/apple/cups/master/conf/mime.convs.in
systemctl restart cups
Version: 2.0.2 CUPS.org User: alexk
When i compile and install CUPS 2.0.2 on Ubuntu 12.04, its web interface is broken because cups.css doesn't load.
Browser says: The stylesheet https://printserver/cups.css was not loaded because its MIME type, "application/x-csource", is not "text/css".
$ file -l /usr/share/cups/doc-root/cups.css