Kunena 7.0.7 Released

The Kunena team has announce the arrival of Kunena 7.0.7 [K 7.0.7] in stable which is now available for download as a native Joomla extension for J! 5.4.x/6.0.x./6.1.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 7.0

Question [JomSocial activity stream] text limiter

More
16 years 5 months ago #38961 by drjjw2
xillibit wrote:

Hello,

I have a way with a little of hacking, open the file components\com_kunena\template\default\post.php and at line 265 add just this part of code, like you see you can change the number allowed for an new entry for the JS activity stream :) :

Code:
$nbrWordMax = '50'; //Define the maximum words allowed in the post $NewString = ''; $t_newString = explode(" ",$message); foreach ($t_newString as $key => $word) { if ($key < $nbrWordMax) { $Newmessage .= $word.' '; } } $message = $Newmessage;


But if I'm not mistaken, this will break links and images that may appear in the post if the word count lands in the middle of a link.

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

More
16 years 5 months ago - 16 years 5 months ago #38973 by dyvel
It should not be done by hacking kunena core, but only through a plugin, as it would otherwise get deleted on future upgrades of kunena (1.6 being just around the corner)...

But it's a start :)
Last edit: 16 years 5 months ago by dyvel.

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

More
16 years 5 months ago #38975 by drjjw2
dyvel wrote:

It should not be done by hacking kunena core, but only through a plugin, as it would otherwise get deleted on future upgrades of kunena (1.6 being just around the corner)...

But it's a start :)



Does a URL get interpreted as a single word?

Also, there would be no readmore link in this hack

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

More
16 years 5 months ago - 16 years 5 months ago #38976 by dyvel
that depends - it the url is constructed like <a href="someurl">this is a url</a> then you might end up cutting the url after the word this, and thus breaking html and the link
Last edit: 16 years 5 months ago by dyvel.

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

More
16 years 5 months ago #39286 by JBMoney
In JomSocial (at least the current version), there is a setting in "Layout" labeled "Display activity contents on page load". If you set it to 'no' then it doesn't show the text at all, but still indicates replies and new threads.

Maybe not ideal in the long term, but a decent short term solution until a non-hack text delimiter is available (e.g., if you don't want a page that is a mile long).

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

More
16 years 5 months ago #39288 by dyvel
I know, but the activitystream is just so much more "alive" with forum "quotes", images and video thumbs etc...

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

Time to create page: 0.291 seconds