jDownloads Support Forum

Older Versions => jDownloads 3.2 (Support ended) => Bugs => Topic started by: marcodings on 23.12.2019 17:42:50

Title: jdownlods content plugin fails on introtext and fulltext
Post by: marcodings on 23.12.2019 17:42:50
Joomla article texts are "split" up in three fields (text, introtext and fulltext), the jdowloads plugin only "processes" the "$article->text" which seems to work with core content layouts, this however is NOT enough.

A custom alternate layout that uses "$article->introtext" and/or "$article->fulltext" will fail in having jdownloads rendered.

To fix, At plugins/content/jdownloads/jdownloads.php:170

$article->introtext = preg_replace_callback($regex, "jd_file_callback", $article->introtext);
$article->fulltext = preg_replace_callback($regex, "jd_file_callback", $article->fulltext);

should be added to ensure full processing of an article texts
Title: Re: jdownlods content plugin fails on introtext and fulltext
Post by: ColinM on 25.12.2019 10:12:35
Hi
Thankyou for your very useful observation.Think this only applies when using a Readmore - is that correct?Colin
Title: Re: jdownlods content plugin fails on introtext and fulltext
Post by: marcodings on 30.12.2019 12:19:26
Nope, This applies to any article using an alternate article layout or override in the template that uses introtext and or fulltext for the rendering of an article.