What path to stylesheets?

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
terimurphy
Forum Members
Forum Members
Posts: 41
Joined: Sat Nov 26, 2005 1:15 am

What path to stylesheets?

Post by terimurphy »

When i put a stylesheet link in my template, what path should I use:

1. If I used the box provided to input the css, or,

2. If I just want to upload a stylesheet directly--where is the best place to put it?

thanks
--apologies if I've double posted, I can't find what I thought I posted before.
terimurphy
Forum Members
Forum Members
Posts: 41
Joined: Sat Nov 26, 2005 1:15 am

Re: What path to stylesheets?

Post by terimurphy »

So you're telling me I have to use hard links with the full path?
And thus I guess that must be true when I have a link in the content from one page of the site to another, heh?

teri
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm

Re: What path to stylesheets?

Post by calguy1000 »

Incase you didn't understand what Patricia mentioned,  The easiest way (if you're not aware already)  is to create a new stylesheet under the Layout->Stylesheets menu, copy and paste your existing stylesheet into there, and then associate that stylesheet with your template.  in CMS, the stylesheets and templates can be stored in the database, making it easy to re-use templates and stylesheets on your site.

Then make sure your template has the {stylesheet} tag somewhere in the head section. 

Then any pages using that template will automatically get the associated stylesheet.

BTW, you can create and associate more than one stylesheet with a template, if you didn't know already.

Hope this helps.
terimurphy wrote: So you're telling me I have to use hard links with the full path?
And thus I guess that must be true when I have a link in the content from one page of the site to another, heh?

teri
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
terimurphy
Forum Members
Forum Members
Posts: 41
Joined: Sat Nov 26, 2005 1:15 am

Re: What path to stylesheets?

Post by terimurphy »

Sorry to be dense, but I still don't get how to use two stylesheets. My template currenly says:

Code: Select all

{stylesheet}

<link href="http://pcifchurches.org/tmp/templates/church_main.css" rel="stylsheet" type="text/css" media="screen" />
And the top one works fine, but the bottom one isn't kicking in.
And if I did store them both in the database, would I need something like:

Code: Select all

{stylesheet1} {stylesheet2}
or what?
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm

Re: What path to stylesheets?

Post by calguy1000 »

You should create a second stylesheet under "Layout --> Stylesheets --> Add A Stylesheet (link at the bottom of the page)"  and included the contents of http://pcifchurches.org/tmp/templates/church_main.css
in this stylesheet,

Secondly, after hitting apply you will be returned to the stylesheets page, you will see a "css" icon.  clicking on this icon (in the same row as your new stylesheet) will allow you to attach that stylesheet to the template of your choice.

Then, no, you should only need the single {stylesheet} tag in your template.
terimurphy wrote: Sorry to be dense, but I still don't get how to use two stylesheets. My template currenly says:

Code: Select all

{stylesheet}

<link href="http://pcifchurches.org/tmp/templates/church_main.css" rel="stylsheet" type="text/css" media="screen" />
And the top one works fine, but the bottom one isn't kicking in.
And if I did store them both in the database, would I need something like:

Code: Select all

{stylesheet1} {stylesheet2}
or what?
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Post Reply

Return to “CMSMS Core”