We've added a second site to our EE setup using MSM (and we use Master Config too). The structure is something like this (site1 is web root; site2 is a subdomain technically):

  • master-config
  • site1
  • site2
  • system
  • templates

The templates output correctly and if we're in the CP, we're able to upload images to the second site just fine. The images for the second site live under site1: site1/assets/images-site2/.

The problem is that although we're able to get into Assets in the CP and manage images just fine, the tags for images don't output anything at all in our template(s). Nothing shows up in the source code; no errors in console; nothing.

I'm not sure if this is a cross-domain issue or something else. Any tips, suggestions, ideas would be great.

We're running EE 2.9.2 with Assets 2.5 in a multi-environment setup (local, dev, prod).

  • Do you have different upload locations for the various MSM sites? If so you should override them all in your master config (upload_preferences). I have this setup working fine on a site. Jan 29 '15 at 11:43
  • I did, but no matter what I put in there, it wouldn't work. Do you have a code example by any chance? Jan 29 '15 at 17:19
  • Could you explain a bit more what exactly is happening; ie. are you able to use {exp:channel:entries} to get the regular channel data, but if you loop a assets tag you get nothing? 1. ie no {filename}? Does it loop at all? (ie. if you just output "hello"? Jan 30 '15 at 10:01
  • Yep, that's exactly it - {exp:channel:entries} works fine. Looping assets outputs nothing - not even the raw tag. Tried plain text too in the assets loop and also nothing. Tried re-indexing files but that didn't help. We ended up using the native File field which worked fine but it'd be nice to find a solution to this for future reference. I'm sure it's a case of PEBCAK. Jan 30 '15 at 16:56
  • Double check the server path for the second site. Hardcoding it worked for me. You should move it to config.php: 4 => array( 'name' => 'Images', 'server_path' => '/home/public_html/second-site/public/images/', 'url' => '/public/images/' ),
    – SteveO
    Sep 10 '15 at 18:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.