Page 1 of 1

Broken rewritten image paths in 0.13b4

Posted: Tue May 16, 2006 9:30 pm
by Synchro
I can upload images no problem, they appear correctly in content chunks when using FCKEditor, but when they're viewed on my site, the images are broken. I'd guess it's a problem with mod_rewrite (which I am using) config.

A path to a typical image (a broken one) might be:

http://www.example.com/index.php/upload ... yimage.jpg

In the editor, this appears as 'uploads/images/myimage.jpg', so the relative path is right - mod_rewrite must be getting the root wrong.

And I can confirm that the really is an image called myimage.jpg in uploads/images.

Incidentally, is there any particular reason to retain the index.php in the rewritten URL? As far as I'm concerned, the main point of rewriting URLs is to remove such syntax.

Re: Broken rewritten image paths in 0.13b4

Posted: Tue May 16, 2006 10:40 pm
by Ted
If you put a {metadata} tag in your tag, it should fix the problem.  The {metadata} tag will spit out a base tag that will set the path that all relative paths will continue on from.

Re: Broken rewritten image paths in 0.13b4

Posted: Wed May 17, 2006 1:23 am
by Elijah Lofgren
Synchro wrote: Incidentally, is there any particular reason to retain the index.php in the rewritten URL? As far as I'm concerned, the main point of rewriting URLs is to remove such syntax.
You just need to create a .htaccess file to mod_rewrite and then change some options in config.php.
See: http://wiki.cmsmadesimple.org/index.php ... ricks  ;)