Kunena 6.3.0 released

The Kunena team has announce the arrival of Kunena 6.3.0 [K 6.3.0] in stable which is now available for download as a native Joomla extension for J! 4.4.x/5.0.x/5.1.x. This version addresses most of the issues that were discovered in K 6.2 and issues discovered during the last development stages of K 6.3

Topics that are moved into this category are generally considered to be closed. Users may want to add additional information but these topics should not be resurrected in order to discuss new problems or unrelated matters.

Question Remove hard coded css styles?

More
13 years 6 months ago - 13 years 6 months ago #1 by wabugi
Hi everybody!

I've just installed Kunena 1.6 stable and I'm creating a new template based on the example template. I've found some hard coded css styles in the website header that are created by Kunena:
Code:
<style type="text/css"> <!-- /* Kunena Custom CSS */ #Kunena div.kheader { background: #5388B4 } #Kunena div.kannouncement div.kheader { background: #990000 } #Kunena div#kannouncement .kanndesc { background: #FFFFAA } #Kunena div.kfrontstats div.kheader { background: #000000 } #Kunena div.kwhoisonline div.kheader { background: #3B5323 } #Kunena .kicon-profile { background-image: url("http://MYJOOMLAURL/components/com_kunena/template/default/media/iconsets/profile/default/default.png"); } #Kunena .kicon-button { background-image: url("http://MYJOOMLAURL/components/com_kunena/template/default/media/iconsets/buttons/default/default.png"); } #Kunena #kbbcode-toolbar li a,#Kunena #kattachments a { background-image:url("http://MYJOOMLAURL/components/com_kunena/template/default/media/iconsets/editor/default/default.png"); } /* End of Kunena Custom CSS */ --> </style>

As you can see it is commented out and should be ignored by the browser. But actually it is not.
Can anybody tell me in which file I can find the code to remove it?
Last edit: 13 years 6 months ago by wabugi.

Please Log in or Create an account to join the conversation.

More
13 years 6 months ago #2 by wabugi
Ok, I found it by myself.

The code is in the template.xml of my template ;)

Please Log in or Create an account to join the conversation.

More
13 years 6 months ago #3 by severdia
They aren't actually hardcoded. You can change them in the Kunena admin and they override the CSS file. But if you don't need them, you can remove it.

Author of Using Joomla from O'Reilly Media. | www.usingjoomlabook.com

Please Log in or Create an account to join the conversation.

More
13 years 6 months ago #4 by fxstein
These are them template parameter. If you do your own template you can decide which ones you want as backend parameters - those you would pass like these. Set them up in the xml and load them in your own copy/version of initialize.php for your template.

Hope this helps!

We love stars on the Joomla Extension Directory . :-)

Please Log in or Create an account to join the conversation.

More
13 years 6 months ago #5 by wabugi
Thanks for your answers. I decided to just remove them from the template.xml because I have really no use for these parameters.

Please Log in or Create an account to join the conversation.

More
13 years 6 months ago #6 by Matias
Also remove them from initialize.php (if it's not in your template, copy it into there).
The following user(s) said Thank You: wabugi

Please Log in or Create an account to join the conversation.

More
13 years 6 months ago #7 by wabugi
Thanks Matias!
I stopped working on the template for some days and just realized that the styles were still there. I was lucky that you already posted the solution for my problem ^^

Please Log in or Create an account to join the conversation.

More
13 years 6 months ago #8 by caplinq
Hmmm... I'm having a hard time finding the file.
I checked the template.xml file in the com_kunena/template/default folder but it's not there, is it?

Also, I did a search for the initialize.php file, and it's not found either. I'm not a newbie at this, what am I doing wrong?

Please Log in or Create an account to join the conversation.

More
13 years 6 months ago #9 by caplinq
Ok, I found it...
In the template.xml file - which is indeed here:
com_kunena/template/default/template.xml
I commented out the <params> that defined the CSS

For the initialize.php file, I don't know why i didn't find it before, it's here:
com_kunena/template/default/initialize.php

and in this file I deleted the /*Kunena Custom CSS */ details.

I don't quite iunderstand why it's here instead of in CSS file, but probably to make it easier for beginners to make basic changes.

Please Log in or Create an account to join the conversation.

More
13 years 3 months ago #10 by WebbR
It is maybe simple for people who are not familiar with css but an option to disable it would be very helpfull. I was like serching for some time to figure out why my changes in the css did't work and then again some time to find out how to disable the custom css in the sourcecode.

Anyway Thx for the solution here in this posting!

Please Log in or Create an account to join the conversation.

Time to create page: 0.543 seconds