0
Welcome Guest! Login
0 items Join Now

How to assign different styles/colors to differents parts of a site

  • How to assign different styles/colors to differents parts of a site

    Posted 17 years 3 months ago
    • Is there a quick and easy way to change the color of the theme for each section of a site. I would like to have the main page be blue, services page be yellow and so forth. Please let me know. Thanks.
    • Last Edit: 17 years 3 months ago by Harold Card.
    • Bob Ateah's Avatar
    • Bob Ateah
    • Elite Rocketeer
    • Posts: 4521
    • Thanks: 0

    Re: How to assign different styles/colors to differents parts of a site

    Posted 17 years 3 months ago
    • Quick and easy - no.

      What you could do is edit your template colours as required for each page, repackage the template(s) (with a unique name for each) that you've created with the new colours, install them on your site and then assign a different template to each page.

      A bit of work, but this will achieve the results that you desire.

      Cheers!
    • The member formerly known as Roland Deschain
      After your question is solved, please Edit your original post and choose the Solved message icon, thank you!
  • Re: How to assign different styles/colors to differents parts of a site

    Posted 17 years 3 months ago
    • Thanks for the info. The only part of that I don't know how to do, is assign a "different" template to a page / section of my site. How is this done through the Joomla cpanel?
    • Bob Ateah's Avatar
    • Bob Ateah
    • Elite Rocketeer
    • Posts: 4521
    • Thanks: 0

    Re: How to assign different styles/colors to differents parts of a site

    Posted 17 years 3 months ago
    • Harold Card wrote:
      Thanks for the info. The only part of that I don't know how to do, is assign a "different" template to a page / section of my site. How is this done through the Joomla cpanel?

      Log in to the admin backend and choose Site/ Template Manager/ Site Templates.

      Choose the template that you want to assign by clicking the circle to the left of the template name and then click the Assign button.
      In the Assign Template area, choose which pages that you want to assign the template to - hold the Ctrl key down for multiple but non-concurrent choices.

      Save, repeat as need be for other templates/ pages.

      Good luck and cheers!
    • The member formerly known as Roland Deschain
      After your question is solved, please Edit your original post and choose the Solved message icon, thank you!
    • Youyou's Avatar
    • Youyou
    • Elite Rocketeer
    • Posts: 699
    • Thanks: 0

    Re: How to assign different styles/colors to differents parts of a site

    Posted 17 years 3 months ago
    • I think the better way for that is not to assign different template because you will have to load many more images and css.
      The best way is to modify a bit the top of you index.php.

      For example for Jomla 1.0 , if in the top of the index.php you see:
      $color=blue;

      You replace that by:
      if( $_REQUEST['option'] == "com_smf" ) { 
      $color=orange;
      }
      elseif( $_REQUEST['option'] == "com_frontpage" ) { 
      $color=green;
      }
      else{
      $color=blue;
      }

      That will loads orange style on the forum, green style on the frontpage and blue for all the others pages.
      You can also use different requested variables like Itemid ...
      I hope it helps ;)

      PS: It will be nice if you edit your first message to change the title to "How to assign different styles/colors to differents parts of a site ?"
      It think it will be more clear ;)
    • Last Edit: 17 years 3 months ago by Youyou.
  • Re: How to assign different styles/colors to differents parts of a site

    Posted 17 years 3 months ago
    • Thanks for the detailed response. I will give this a try. Please note that I've changed the title as per your recommendation.
  • Re: How to assign different styles/colors to differents parts of a site

    Posted 17 years 3 months ago

Time to create page: 0.233 seconds