Kunena 6.4.8 Released

The Kunena team has announce the arrival of Kunena 6.4.8 [K 6.4.8] in stable which is now available for download as a native Joomla extension for J! 5.0.x/5.1.x/5.2.x/5.3.x/5.4.x. This version addresses most of the issues that were discovered in K 6.2 / K 6.3 / K 6.4 and issues discovered during the last development stages of K 6.4
Important note: Go to the Kunena Dashboard after an upgrade so that the Kunena database tables are also updated. This is particularly necessary for major version jumps so that the table changes are adapted.

This category contains miscellaneous, uncategorised user contributions, (templates, modules, plugins and hacks) relating to older versions of Kunena that are no longer supported.

The topics in this category are for historical interest only. Owing to the structural changes that occurred in K 1.7, many of the ideas in these topics will not work with later versions and, for that reason, the topics are locked.

Question Implementation of LaTeX

More
14 years 11 months ago - 14 years 11 months ago #85960 by flo310
Hello,

I needed to implement latex to my forum, so I did it today.
It works with Kunena 1.6 and Joomla 1.5.22.

First of all download the MiMeTex plugin :
Here

Install it, and Enable it.

Then go to Kunena->Config->Website and put yes to 'Support Joomla plugins'.

Be careful because it allows members to put a plugin code in their message, so set the right access to the other plugins.

Now we need to add a boardcode.

Go to com_kunena/lib/kunena.bbcode.js.php

and add the following lines (I decided to add it after the color code)
Code:
kbbcode.addFunction('LaTeX', function() { this.wrapSelection('{tex}', '{/tex}', false); },{'id': 'kbbcode-tex-button', 'title': '<?php echo JText::_('LaTeX');?>', 'alt': '<?php echo JText::_('LaTeX');?>', 'onmouseover' : '$("helpbox").set("value", "<?php echo JText::_('LaTeX : {tex}code latex{/tex}');?>")'});
then add the following line in
com_kunena/lib/kunena.smile.class.php in the function purity
Code:
$text = preg_replace ( '/\{tex(.*?)\}(.*?)\{\/tex\}/s', '\\2', $text );
and to the css of your Joomla or Kunena template
Code:
#Kunena ul#kbbcode-toolbar li a#kbbcode-tex-button { background:url('../images/latex.png') no-repeat; } #Kunena ul#kbbcode-toolbar a:hover#kbbcode-tex-button { background-color:#e4e4e4; }
where latex.png is the image to be displayed on the boardcode.
Notice that his size should be 18x18 px to have a good render.

And you are done :)

PS : Sorry for my English, Iam a french student :P


Last edit: 14 years 11 months ago by flo310.

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

Time to create page: 0.320 seconds