Problem with image paths

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Post Reply
fooBar
Forum Members
Forum Members
Posts: 32
Joined: Thu Dec 28, 2006 3:10 pm

Problem with image paths

Post by fooBar »

Hello,

I have a slight problem:

when I insert an image with the editor in the admin cp, the code looks like:



(attention to the path!!).

the image is displayed correctly in the editor so the path seems to be correct.

the problem is:

I'm using the newest CMS version as multilanguage package and I'm using mod_rewrite, so my page url looks like:

http://www.domain.de/de/pageXYZ/

so the path "uploads/images/page/anfahrt/anfahrt_03.jpg" is not correct anymore and the image isn't shown.,.. Is it possible to change the behaviour of the editor to always insert absolute urls to the files ("/uploads/images/page/anfahrt/anfahrt_03.jpg")??

thanks!
fooBar
Forum Members
Forum Members
Posts: 32
Joined: Thu Dec 28, 2006 3:10 pm

Re: Problem with image paths

Post by fooBar »

Ok, I found this solution:

http://forum.cmsmadesimple.org/index.ph ... 777.0.html

But the problem is: I cannot add to the head because I'm using links like the following:

...

but they do not work anymore after using the base because when hte link is on the page:

domain.de/asd/asd2/

the link links to

domain.de/?cmd=...

instead of:

domain.de/asd/asd2/?cmd=...

how to fix it?

thanks!
fooBar
Forum Members
Forum Members
Posts: 32
Joined: Thu Dec 28, 2006 3:10 pm

Re: Problem with image paths

Post by fooBar »

is it perhaps possible tp configure cmsmadesimple to use absolute paths so that I don't need the base-tag in the section and all links still work properly???
Pierre M.

Re: Problem with image paths

Post by Pierre M. »

Hello,

same problem here, CMSms v1.5.1.
I use pretty URLs : /some/page.html
Inserted images are as you say :
I don't like the tag so I have {metadata showbase="false"}
So, on /some/page.html, /some/uploads/images/myfolder/mypic.jpg is obviously 404 not found.
It should be /uploads/images/myfolder/mypic.jpg

Solution :
Extensions->TinyMCE wysiwyg
"Advanced" tab.
Uncheck "generate relative URLs".

Pierre M.
fooBar
Forum Members
Forum Members
Posts: 32
Joined: Thu Dec 28, 2006 3:10 pm

Re: Problem with image paths

Post by fooBar »

Yeah, that's it :) Very nice!!!!
Pierre M.

Re: Problem with image paths

Post by Pierre M. »

Wait...
I have another problem now : those nice relative links don't include my ".html" suffix :-(
Or I'm missing something else ?

Pierre M.
Pierre M.

Re: Problem with image paths

Post by Pierre M. »

I have just submitted bug #2815.
Post Reply

Return to “CMSMS Core”