moodle not showing CSS and theme with linux server

匿名 (未验证) 提交于 2019-12-03 02:27:02

问题:

I'm experiencing a problem regarding Moodle.

I've made an install into a Linux server, but CSS and themes are not displaying so i have only plain text.

How can this be possible and how to solve it?

Thanks.

回答1:

This solution should work. I ran into the same problem after I migrated from local to production and I had to disable Use slash arguments in

Sites Administration > Server > HTTP.

It is the first item you see on the page. Just deselect it if it is checked and save to see if that helps.



回答2:

Today i installed the latest moodle 3.2 on Linux Ubuntu server with Apache2 and PHP5.6. After successful installation, on the final screen no css or js was loading. pretty much similar to your issue. Getting ERR_CONTENT_DECODING_FAILED when url is hit

/theme/yui_combo.php?rollup/3.17.2/yui-moodlesimple-min.css  

I did some googling and found that its related to zlib compression and after enabling it in my php.ini file the problem is solved.

Locate your php.ini files, Go to php.ini file

sudo vi /etc/php/5.6/apache2/php.ini 

Add or set below 2 lines

zlib.output_compression = on zlib.output_compression_level = 6 

Restart apache

sudo service apache2 restart 

It will start working fine.

Related problem: https://moodle.org/mod/forum/discuss.php?d=324581#p1421502



回答3:

It seems that you are viewing the moodle with standard theme.

By default in moodle the standard theme would be applied. You can choose any other theme which is available under the theme section.

To change the theme, you will to have access the theme section page as admin.

 Administration > Site administration > Appearance > Themes > Theme Selector 

After select any other theme, you will have to do purge all cache.

For more information about changing the theme: Change moodle theme



回答4:

If you are using nginx make sure your config file in /etc/nginx/sites-enabled/[your site] is according to the directions from moodle. Copy this config https://docs.moodle.org/32/en/Nginx



回答5:

Have you checked your web server to see if there are any error messages?

Next, have you tried looking in your web browser developer tools, to see if there are any errors there (especially 404 errors)?

Finally, make sure debugging is on for your Moodle site (right up to developer level) and see if that sheds some light on the problem.

You might also want to check that all of your Moodle data folder is writable, as otherwise Moodle may have trouble generating the cached theme files.



标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!