jDownloads Support Forum

Older Versions => jDownloads 3.2 (Support ended) => General => Topic started by: romagromov on 25.07.2015 14:02:53

Title: How to add category link in file details page?
Post by: romagromov on 25.07.2015 14:02:53
How to add category link in file details page?

(http://monosnap.com/image/Ufevn4W0Qmd5ftsd7CXOiX4llbn80h.png)
Title: Re: How to add category link in file details page?
Post by: romagromov on 25.07.2015 18:47:10
Ok, I got it.

May be somebody will find this helpful.

Open file
/components/com_jdownloads/views/downloads/tmpl/default.php

find code about line 378

$body = str_replace('{changelog_value}', $this->item->changelog, $body);

add after this libe code:

$catlink = JRoute::_("index.php?option=com_jdownloads&view=category&catid=".$this->item->cat_id."&Itemid=");
$body = str_replace('{cat_title}', '<a href="'.$catlink.'">'.$this->item->category_title.'</a>', $body); 


Then add placeholder to details layout - {cat_title}


I only can't understand how get Itemid= for this link.