- Posts: 11
COMMUNITY FORUM
using a formula - and where to place the css?
- Jos
-
Topic Author
- Offline
- New Member
Less
More
14 years 8 months ago #88594
by Jos
using a formula - and where to place the css? was created by Jos
I'm quite new at K2, I have two questions I need some help with:
I have a client who sells products. He doesn't need a shopping cart, and he has two prices: a price to agents (+10%) and to direct clients (+15%). He wants to enter an article just once (each in a category), and update it using the formula in a custom field. Is that possible?
He works a lot with spreadsheets, and that is why he wants it. My opinion is that you have to copy and paste the article 2 times, and set the prices by hand. But maybe something can be done in the custom fields?
The custom fields got my attention to K2. I like it very much, but try as I may, I can't get the k2.ss working in a micro template. Setting it up is explained very clear in the various tutorials. But I can't figure out where to place the css file. Whatever I do, I always end up the the k2.css in the com_k2 component itself.
I copied the default folder + contents to /template/html/com_k2. Rename it. I can immediately select that new micro template in the category. But I am not able to get an independent CSS working.
Suppose I want 3 micro templates, where the only change is the background color in red, white and blue. I copy the default + contents folder inside the template folder three times, rename them red, white and blue. Where do I add or set up the css so the back becomes that color?
Thanks for any help. I'm struggling weeks on this one.
I have a client who sells products. He doesn't need a shopping cart, and he has two prices: a price to agents (+10%) and to direct clients (+15%). He wants to enter an article just once (each in a category), and update it using the formula in a custom field. Is that possible?
He works a lot with spreadsheets, and that is why he wants it. My opinion is that you have to copy and paste the article 2 times, and set the prices by hand. But maybe something can be done in the custom fields?
The custom fields got my attention to K2. I like it very much, but try as I may, I can't get the k2.ss working in a micro template. Setting it up is explained very clear in the various tutorials. But I can't figure out where to place the css file. Whatever I do, I always end up the the k2.css in the com_k2 component itself.
I copied the default folder + contents to /template/html/com_k2. Rename it. I can immediately select that new micro template in the category. But I am not able to get an independent CSS working.
Suppose I want 3 micro templates, where the only change is the background color in red, white and blue. I copy the default + contents folder inside the template folder three times, rename them red, white and blue. Where do I add or set up the css so the back becomes that color?
Thanks for any help. I'm struggling weeks on this one.
Please Log in or Create an account to join the conversation.
- william white
-
- Offline
- Platinum Member
Less
More
- Posts: 3722
14 years 8 months ago #88595
by william white
Replied by william white on topic using a formula - and where to place the css?
Get css for K2 and it will probably solve your css problems
simon.getk2.org/downloads/free-extensions/item/26-css-4-k2
the formula question requires thought
simon.getk2.org/downloads/free-extensions/item/26-css-4-k2
the formula question requires thought
Please Log in or Create an account to join the conversation.
- Jos
-
Topic Author
- Offline
- New Member
Less
More
- Posts: 11
14 years 8 months ago #88596
by Jos
Replied by Jos on topic using a formula - and where to place the css?
I only wish! I've tried that many times as well. Followed the instructions step by step. Tried various settings on the plugin. Whatever I do, the css remains the k2.css in the com-K2 component.
I'm certain it works, but I am still stumped.
I'm certain it works, but I am still stumped.
Please Log in or Create an account to join the conversation.
- william white
-
- Offline
- Platinum Member
Less
More
- Posts: 3722
14 years 8 months ago #88597
by william white
Replied by william white on topic using a formula - and where to place the css?
k2.css should be copied and placed into
httpdocs/templates/YourTemplate/html/com_k2/templates/YourOverrideDirectory
It should be remamed to YourOverrideDirectory_style.css
Examine with firebug
httpdocs/templates/YourTemplate/html/com_k2/templates/YourOverrideDirectory
It should be remamed to YourOverrideDirectory_style.css
Examine with firebug
Please Log in or Create an account to join the conversation.
- Jos
-
Topic Author
- Offline
- New Member
Less
More
- Posts: 11
14 years 8 months ago #88598
by Jos
Replied by Jos on topic using a formula - and where to place the css?
I've done it like this:
\wamp\www\k2\templates\rhuk_milkyway\html\com_k2\templates\test\
test_style.css
doesn't make any difference if I place test_style.css inside or above the test folder.
I checked with firebug, it keeps referring to k2.css
\wamp\www\k2\templates\rhuk_milkyway\html\com_k2\templates\test\
test_style.css
doesn't make any difference if I place test_style.css inside or above the test folder.
I checked with firebug, it keeps referring to k2.css
Please Log in or Create an account to join the conversation.
- william white
-
- Offline
- Platinum Member
Less
More
- Posts: 3722
14 years 8 months ago #88599
by william white
Replied by william white on topic using a formula - and where to place the css?
That looks correct
The only other settings i use in the plugin are
Enabled
Public
Keep K2Css - Yes
Force Original - No
Force Deafault - No
The only other settings i use in the plugin are
Enabled
Public
Keep K2Css - Yes
Force Original - No
Force Deafault - No
Please Log in or Create an account to join the conversation.
- Jos
-
Topic Author
- Offline
- New Member
Less
More
- Posts: 11
14 years 8 months ago #88600
by Jos
Replied by Jos on topic using a formula - and where to place the css?
Whatever settings I try, I only can work with the original k2.css
the test_style.css is not picked up. I placed it in the folder and above the folder.
Changed the settings of the plugin. No go.
the test_style.css is not picked up. I placed it in the folder and above the folder.
Changed the settings of the plugin. No go.
Please Log in or Create an account to join the conversation.
- Jos
-
Topic Author
- Offline
- New Member
Less
More
- Posts: 11
14 years 8 months ago #88601
by Jos
Replied by Jos on topic using a formula - and where to place the css?
I got it!
I did everything right. Except... I didn't know the new created template only works on new articles you create.
I assigned the 'test' micro theme to the category latest. Checked it on the articles already there. Nothing.
Once I created a new article, immediately the test_style.css showed up and did its work.
Maybe that could be included in the tutorial? It stumped me literally for weeks. I'm sure I'm not the only one.
I did everything right. Except... I didn't know the new created template only works on new articles you create.
I assigned the 'test' micro theme to the category latest. Checked it on the articles already there. Nothing.
Once I created a new article, immediately the test_style.css showed up and did its work.
Maybe that could be included in the tutorial? It stumped me literally for weeks. I'm sure I'm not the only one.
Please Log in or Create an account to join the conversation.
- william white
-
- Offline
- Platinum Member
Less
More
- Posts: 3722
14 years 8 months ago #88602
by william white
Replied by william white on topic using a formula - and where to place the css?
I think there could have been a cache problem or something because i havent seen that before.
Please test by createing a new category first
Add an article
get it displaying from a menu choice
create an override and a custom css for that category and select it
Is should work on items already created when they display
Please test by createing a new category first
Add an article
get it displaying from a menu choice
create an override and a custom css for that category and select it
Is should work on items already created when they display
Please Log in or Create an account to join the conversation.
- alex a
-
- Offline
- New Member
Less
More
- Posts: 1
14 years 8 months ago #88603
by alex a
Replied by alex a on topic using a formula - and where to place the css?
would someone PLEASE fix the CSS4K2 BROKEN LINK! I need to DL it!
Please Log in or Create an account to join the conversation.
- william white
-
- Offline
- Platinum Member
Less
More
- Posts: 3722
14 years 8 months ago #88604
by william white
Replied by william white on topic using a formula - and where to place the css?
Please Log in or Create an account to join the conversation.