PrestaCraft on Facebook

Please like our page on Facebook to get notifications about new tutorials :)


PrestaCraft

PrestaCraft on Facebook

Please like our page on Facebook to get notifications about new tutorials :)


PrestaCraft

There problem appears if You don’t see any images in File manager and/or TinyMCE editor.

It looks like this.


You can easily track a thumbnail URL by right clicking on it and then clicking show URL.

I assume that Your URL shows something similiar to:
http://your_prestashop_path/adminXXX/img/cms/Image.jpg

But if You check in Your browser the same URL without /adminXXX part, an image will appear, right?
If so, that’s the reason of problem. You need to get rid of adminXXX in Your URL.

   Edit:   /adminXXX/filemanager/config/config.php
  Find:

$upload_dir = __PS_BASE_URI__.'img/cms/';

  Replace with:

$upload_dir = preg_replace('/\/admin\d*\//i','/',__PS_BASE_URI__).'img/cms/';

If above will not work, replace with:

$upload_dir = '/img/cms/';

   Edit:   /adminXXX/filemanager/dialog.php
  Find:

$mini = $thumb = __PS_BASE_URI__.substr($thumbs_path.$subdir.$file, strlen(_PS_ROOT_DIR_) + 1);

  Replace with:

$mini = $thumb = preg_replace('/\/admin\d*\//i','/',__PS_BASE_URI__).substr($thumbs_path.$subdir.$file, strlen(_PS_ROOT_DIR_) + 1);

If above will not work, replace with:

$mini = $thumb = '/'.substr($thumbs_path.$subdir.$file, strlen(_PS_ROOT_DIR_) + 1);

Leave a comment

Your email address will not be published.

Be the first to post a comment!

Leave a comment

Your email address will not be published.