I turned on Optimize CSS files in admin/settings/performance and now my site has no styles at all. The directory is writable and I see that Drupal created a few css files in there. /ho开发者_StackOverflow中文版me/drupal/sites/mysite.com/files/css
thanks
We had this problem and it turned out that our /tmp mount was full. We had been generating cachegrinds inadvertently and it filled up.
So, if you get empty css and js aggregates try running "df" and see if there is space left in /tmp. If not ... clear some out.
I would try these two things first.
- Clear drupal cache. Admin->settings->performance->clear cached data.
- Clear your browser cache.
If that doesn't work, are the files in the /home/drupal/sites/mysite.com/files/css empty?
Save the files in UTF-8 format. I fixed the issue by opening all my css files in a text editor and saving them in UTF-8 Encoding format. I noticed that some of them were in ANSI format. Drupal 6.19.
We had this problem because of a quota set on the hosting account. Drupal was only creating blank files in sites/default/files/css. Once we increased the quota the files we able to be created and all returned to normal.
This happened to me because of an .htaccess file planted by Drupal on the files directory. Also, all images on the files directory were gones as well.
The .htaccess file contained the following three lines:
SetHandler Drupal_Security_Do_Not_Remove_See_SA_2006_006
Options None
Options +FollowSymLinks
The file was not compatible with the security settings of the client's host. (Further information available on here).
Renaming the file solved the issue. Other measures like changing the tmp directoy or making sure there is enough disk space or installing the advagg module didn't help.
I had the same problem. Looking at my console log, it said that the css (and js) files couldn't be found even though they were very clearly there.
I found changing the rewritebase in the site .htaccess file to the following fixed it (it was set to something fairly irrelevant):
RewriteBase /
精彩评论