1

I just installed Bolt-CMS and I dont have much time to learn the entire CMS. All my images uploaded to the "files" are not showing even on the dashboard. They get renamed to /1000x1000r/xxxx.xxx and they don't show. Can anyone tell me what's going on, where to configure so that they start showing.

Here is my .htaccess code. I haven't modified it at all:

# 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>

When I open the dashboard filemanager I get the following. Images DO NOT SHOW on the dashboard and on my website.

Here is my browser console log:

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)
Martin
  • 474
  • 2
  • 6
  • 17
  • You should check the apache error log and php error log.. there should be some clues in those about the error you're getting – jadwigo Apr 17 '15 at 08:10
  • What should I look out for in the errorlogs? – Martin Apr 17 '15 at 08:30
  • Try this: If you load one of the files like 'http://localhost/www/bolt/thumbs/54x40c/keyboard-old-technology-2318.jpg' you will probably see a 500 error in your borwser... directly after that the last lines of apache_log, error_log and maybe your php log will show you what happened – jadwigo Apr 20 '15 at 13:57

3 Answers3

7

Simple fix. Here it is. Firstly you need to make sure that in the .htaccess file you uncomment the line # RewriteBase / and set to your local site folder. The HTACCESS file is well documented but the eyes may miss that this is commented. Once you migrate the site to production, don't forget you need to fix this value.

If thumbnails not showing then it means that your php environment needs the file extension to show file info. Find and uncomment the line extension=php_fileinfo.dll Restart Apache and your are good to go!

0

It sounds like the images are uploaded fine but the thumbnails are not showing. In which case it is likely an issue with rewrites. Check that you have the .htaccess file in place if you're using Apache. If you're using nginx see this Github ticket for help.

DisgruntledGoat
  • 70,219
  • 68
  • 205
  • 290
  • I am using apache and I have already installed the CMS to use my localhost mysql database. I have placed the whole CMS and its files to C:\xampp\htdocs\www\bolt, let me edit the question to include my current .htaccess file – Martin Apr 17 '15 at 07:25
0

99% of these problems are caused by incorrect permissions somewhere along the line.

When you request a /thumbs/xxx style url the web server needs to be able to:

  1. Read the original file (files/xxxx.jpg)
  2. Write the created thumbnail into the cache directory (app/cache/xxxx)
  3. Optionally if save_files is true in config.yml make a copy of the thumbnail to the /thumbs folder.

For these folders the web server will need read/write/execute perms for the folders. Check this and see if it sorts things out.

Ross Riley
  • 826
  • 5
  • 8