Latest News Plus Date code issue

  • Posted by TemplatePlazza (5239) Offline
From what I can see from the error code, it seems like you might be using a page builder of some sort. Could it be this one? www.joomlack.fr/en/joomla-extensions/page-builder-ck
6 days 16 hours ago #7 by TemplatePlazza

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

Yes, Joomlack Page Builder version 3.3.7 PRO
6 days 15 hours ago #8 by Tony

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

Hi, Can I assume with you silence that you cannot help me with issue?
1 day 15 hours ago #9 by Tony

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

  • Posted by TemplatePlazza (5239) Offline
Hi Tony, this issue occurs because Pagebuilder CK inserts its parameters into the introtext. In the case of a Joomla article, that code will be processed directly by the Pagebuilder plugins running on the article page. However, for modules that directly retrieve the introtext value, the content of introtext is not processed beforehand.

If you're able to edit the PHP file, you can edit this file:  
/modules//mod_latestnewsplusdate/tmpl/default.php

Find this code on line 60:
<?php
echo JHtmlString::truncate(strip_tags($item->introtext), $introtext_truncate); ?>

Then replace it with:
<?php
$introtxt = $item->introtext;
$introtxt = preg_replace('/\{.*?\}/', '', $introtxt);
$introtxt = preg_replace('/\[.*?\]/', '', $introtxt);
$introtxt = preg_replace('/:[a-z]+\([^)]+\)|\.[a-zA-Z0-9-_]+/', '', $introtxt);
echo JHtmlString::truncate($introtxt, $introtext_truncate, true, false); ?>

Give it a try and let me know how it goes.
22 hours 33 minutes ago #10 by TemplatePlazza

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

Powered by Kunena Forum