Add Stye Sheet for new color J2.5

GK User
Mon Mar 05, 2012 2:29 pm
Hiya,

I have created two new files and put them in the themes CSS folder:

Style5.css
Typography.style5.css

I now need to be able to select it on the admin part.

Where do I add these two files in order for me to select them.

P.S I have just copied Style4.css and changed the colour from Red to a dark Purple.

Thanks
User avatar
Fresh Boarder

GK User
Mon Mar 05, 2012 2:53 pm
Find File: \templates\gk_finance_business\templateDetails.xml
Find Lines: 176 to 181 which is below.
Code: Select all
            <field name="template_color" type="list" default="1" label="TPL_GK_LANG_TEMPLATE_COLOR" description="TPL_GK_LANG_TEMPLATE_COLOR_DESC">
               <option value="1">TPL_GK_LANG_COLOR_1</option>
               <option value="2">TPL_GK_LANG_COLOR_2</option>
               <option value="3">TPL_GK_LANG_COLOR_3</option>
               <option value="4">TPL_GK_LANG_COLOR_4</option>
            </field>

Replace with below
Code: Select all
            <field name="template_color" type="list" default="1" label="TPL_GK_LANG_TEMPLATE_COLOR" description="TPL_GK_LANG_TEMPLATE_COLOR_DESC">
               <option value="1">TPL_GK_LANG_COLOR_1</option>
               <option value="2">TPL_GK_LANG_COLOR_2</option>
               <option value="3">TPL_GK_LANG_COLOR_3</option>
               <option value="4">TPL_GK_LANG_COLOR_4</option>
               <option value="5">TPL_GK_LANG_COLOR_5</option>
            </field>

Find File:\language\en-GB\en-GB.tpl_gk_finance_business.ini
Find Line: 28 which is below.
Code: Select all
TPL_GK_LANG_COLOR_4="red"

Replace with below
Code: Select all
TPL_GK_LANG_COLOR_4="red"
TPL_GK_LANG_COLOR_5="purple"


Do below if you want to make this style available in front end as well.
Find File: \templates\gk_finance_business\layouts\blocks\footer.php
Find Lines: 21 to 26 which is below
Code: Select all
   <p id="gkStyleArea">
      <a href="#" id="gkStyle1">blue</a>
      <a href="#" id="gkStyle2">green</a>
      <a href="#" id="gkStyle3">orange</a>
      <a href="#" id="gkStyle4">red</a>
   </p>

Replace it with below
Code: Select all
   <p id="gkStyleArea">
      <a href="#" id="gkStyle1">blue</a>
      <a href="#" id="gkStyle2">green</a>
      <a href="#" id="gkStyle3">orange</a>
      <a href="#" id="gkStyle4">red</a>
      <a href="#" id="gkStyle5">purple</a>
   </p>


See you around...
User avatar
Platinum Boarder

GK User
Tue Mar 06, 2012 6:58 pm
Is that it?

I have tried it, but it just picks up Style 4 (red) and not the style5 (purple).

In your post, I can it to pick in the drop down, but how does it know style5 is even their ?
User avatar
Fresh Boarder

GK User
Wed Mar 07, 2012 2:41 am
When you add this line "<option value="5">TPL_GK_LANG_COLOR_5</option>" in templatedetails.xml and select it from template settings and save the settings you end getting style option value ="5" , framework pickups up this value "5" and replace it in below files to get style css files.
Style(optionValue).css > Style5.css
Typography.style(optionvalue).css > Typography.style5.css

Variables in template files are different anyway. Above is just an example.
See you around...
User avatar
Platinum Boarder


cron