[Solved] Image not shown due to path problem in 1.11.2
Posted: Sun Sep 23, 2012 10:27 am
I doubt what is the correct method to specify relative path for images in TinyMCE and let CMSMS with Pretty URL show the image with correct path added.
My problem currently:
(1) in the content page, I use "uploads/image/myimage.jpg" for Image URL
(2) The image does not show up because the path of the image becomes:
"http://mysite/my-pretty-url-article/upl ... yimage.jpg
and the correct path for the image should be:
"http://mysite/uploads/images/myimage.jpg
I have to use relative paths because my sites will be put into several servers and I will only need to change the server name in config.php and it works.
My .htaccess is as below:
#php_flag magic_quotes_gpc Off
#php_flag register_globals Off
#php_flag session.use_trans_sid Off
# Make sure you have Options FollowSymLinks
# and Allow on
RewriteEngine On
#Rewrites page.shtml as index.php?page
RewriteCond %{REQUEST_FILENAME} !-f [NC]
RewriteCond %{REQUEST_FILENAME} !-d [NC]
RewriteRule ^(.+)$ index.php?page=$1 [QSA]
Please advise what I shall do.
My problem currently:
(1) in the content page, I use "uploads/image/myimage.jpg" for Image URL
(2) The image does not show up because the path of the image becomes:
"http://mysite/my-pretty-url-article/upl ... yimage.jpg
and the correct path for the image should be:
"http://mysite/uploads/images/myimage.jpg
I have to use relative paths because my sites will be put into several servers and I will only need to change the server name in config.php and it works.
My .htaccess is as below:
#php_flag magic_quotes_gpc Off
#php_flag register_globals Off
#php_flag session.use_trans_sid Off
# Make sure you have Options FollowSymLinks
# and Allow on
RewriteEngine On
#Rewrites page.shtml as index.php?page
RewriteCond %{REQUEST_FILENAME} !-f [NC]
RewriteCond %{REQUEST_FILENAME} !-d [NC]
RewriteRule ^(.+)$ index.php?page=$1 [QSA]
Please advise what I shall do.