My images will not show up

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.
Locked
misstheresa2009
New Member
New Member
Posts: 8
Joined: Wed May 23, 2012 6:50 am

My images will not show up

Post by misstheresa2009 »

Hi Everyone,

I am trying to port over a static html template into CMS Made Simple and I am having a problem getting my images to show up. Before this I kept getting an error saying that {stylesheet} was an unknown tag. I changed it to the new {cms stylesheet} and the error went away. The page now shows up but none of the images can be found. This is very upsetting to me.

Can someone tell me which folder these are supposed to go into? I looked at two videos on YouTube and the answer still is not clear to me.
Wishbone
Power Poster
Power Poster
Posts: 1368
Joined: Tue Dec 23, 2008 8:39 pm

Re: My images will not show up

Post by Wishbone »

With {stylesheet}, it was calling a stylesheet script from your root directory. Now, with {cms_stylesheet} the cached stylesheets are in the /tmp directory, so all images are relative to there.

Use [[root-url]] in your stylesheets.. Example:

Code: Select all

#background {
  background-image: url([[root-url]]/uploads/images/back.jpg);
}
misstheresa2009
New Member
New Member
Posts: 8
Joined: Wed May 23, 2012 6:50 am

Re: My images will not show up

Post by misstheresa2009 »

Wishbone wrote:With {stylesheet}, it was calling a stylesheet script from your root directory. Now, with {cms_stylesheet} the cached stylesheets are in the /tmp directory, so all images are relative to there.

Use [[root-url]] in your stylesheets.. Example:

Code: Select all

#background {
  background-image: url([[root-url]]/uploads/images/back.jpg);
}

It worked! I can see all of my images now. Thank you!
Locked

Return to “CMSMS Core”