我刚刚安装了Bolt-CMS,我没有太多时间学习整个CMS.上传到"文件"的所有图像甚至不会显示在仪表板上.他们被重命名为/1000x1000r/xxxx.xxx,他们没有显示.任何人都可以告诉我发生了什么,在哪里配置,以便他们开始显示.
这是我的.htaccess代码.我根本没有修改它:
# Set the default handler.
DirectoryIndex index.php index.html index.htm
# Prevent directory listing
Options -Indexes
# Make sure MultiViews is disabled if available.
<IfModule mod_negotiation.c>
Options -MultiViews
</IfModule>
<FilesMatch "\.(yml|db|twig|md)$">
<IfModule mod_authz_core.c>
Require all denied
</IfModule>
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
</FilesMatch>
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteRule cache/ - [F]
# Some servers require the RewriteBase to be set. If so, set to the correct folder.
# RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteRule ^ ./index.php [L]
</IfModule>
# set the correct mime type for woff2 font type
# =============================================
# if you don't set your own mimetypes or you aren't using
# HTML5 Boilerplate Server Configs https://github.com/h5bp/server-configs-apache
# then you can uncomment (delete the hash/pound/octothorpe/number symbol) the section below:
#<IfModule mod_mime.c>
# AddType application/font-woff2 woff2
#</IfModule>
Run Code Online (Sandbox Code Playgroud)
当我打开仪表板文件管理器时,我得到以下内容.图片不会显示在仪表板和我的网站上.
这是我的浏览器控制台日志:
files:757 GET http://localhost/www/bolt/thumbs/54x40c/analog-camera-photography-vintage-1844.jpg 500 (Internal Server Error)
files:757 GET http://localhost/www/bolt/thumbs/54x40c/alarm-clock-gold-hands-of-a-clock-1778.jpg 500 (Internal Server Error)
files:597 GET http://localhost/www/bolt/thumbs/54x40c/agriculture-cereals-field-621.jpg 500 (Internal Server Error)
files:918 GET http://localhost/www/bolt/thumbs/54x40c/apple-desk-iphone-2750.jpg 500 (Internal Server Error)
files:918 GET http://localhost/www/bolt/thumbs/54x40c/architecture-books-building-2757.jpg 500 (Internal Server Error)
files:1081 GET http://localhost/www/bolt/thumbs/54x40c/bell-bills-cash-register-2738.jpg 500 (Internal Server Error)
files:1856 GET http://localhost/www/bolt/app/view/js/maps/lib.min.js.map 404 (Not Found)
files:1 GET http://localhost/www/bolt/app/view/js/maps/bolt.min.js.map 404 (Not Found)
files:1081 GET http://localhost/www/bolt/thumbs/54x40c/blur-breakfast-coffee-271.jpg 500 (Internal Server Error)
files:1245 GET http://localhost/www/bolt/thumbs/54x40c/blur-flowers-home-1093.jpg 500 (Internal Server Error)
files:1245 GET http://localhost/www/bolt/thumbs/54x40c/building-frame-garage-1599.jpg 500 (Internal Server Error)
files:1406 GET http://localhost/www/bolt/thumbs/54x40c/california-foggy-golden-gate-bridge-2771.jpg 500 (Internal Server Error)
files:1406 GET http://localhost/www/bolt/thumbs/54x40c/carrot-cooking-eat-1398.jpg 500 (Internal Server Error)
files:1574 GET http://localhost/www/bolt/thumbs/54x40c/configure-disc-jockey-disco-1504.jpg 500 (Internal Server Error)
files:1574 GET http://localhost/www/bolt/thumbs/54x40c/food-fruit-orange-1286.jpg 500 (Internal Server Error)
files:1745 GET http://localhost/www/bolt/thumbs/54x40c/garden-gardening-grass-589.jpg 500 (Internal Server Error)
files:1819 GET http://localhost/www/bolt/thumbs/54x40c/keyboard-old-technology-2318.jpg 500 (Internal Server Error)
Run Code Online (Sandbox Code Playgroud)
小智 7
简单的修复.这里是.首先,您需要确保在.htaccess文件中取消注释#RewriteBase /行并设置为本地站点文件夹.HTACCESS文件已有详细记录,但可能会错过这个评论.将站点迁移到生产环境后,请不要忘记需要修复此值.
如果缩略图未显示则表示您的php环境需要文件扩展名来显示文件信息.查找并取消注释行扩展名= php_fileinfo.dll重新启动Apache,你很高兴!