Hi all,
Just moved my site from www.site.com to www.site.com/old.
Changed everything in control panel etc.
I have a folder set up for channel entry attachments. It collects videos. Simply changed the reference to that and it’s working fine.
But then none of my images are showing. In my templates all the references are relative. So for exmaple, /images/logo.png.
When I render, they still reference www.site.com/images/logo.png instead of www.site.com/old/images/logo.png.
I cannot figure out how to fix this. Everything else seems to be working fine.
Can someone assist?
There’s an issue with your references. You could use “images/foo.png”, in which case it doesn’t matter in what subdirectory you are (as long as it contains a folder named “images” with the appropriate files), but if you use “/images/foo.png” your browser will look for a top-level directory named “images”.
A few things you can try:
1) Simply copy your “images” folder back to the top, i.e. above “old”. There is no harm in having this directory there, even if the new site will have to share.
2) Create a sub-domain by the name of “old”, ie. old.example.com and match it to the “old” directory.
3) Use mod_rewrite.
4) Change your image references with a global search & replace.
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.