News:

Dear forum visitors, if the support forum is not available, please try again a few minutes later. Thanks!

Main Menu
Support-Forum

RsComment for jdownload

Started by mehrabun, 15.09.2015 10:07:54

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

mehrabun

Hello,
I want to use rscomment in the jdownload. We should use of this code:
{rscomments_no option="com_jdownloads" id=""}
{rscomments option="com_jdownloads" id=""}

https://www.rsjoomla.com/support/documentation/rscomments/frequently-asked-questions-/how-can-i-enable-comments-on-a-page-.html
{rscomments_no option="com_jdownloads" id="{file_id}"}
{rscomments option="com_jdownloads" id="{file_id}"}

we should have an ID for suitable function.
{file_id} in "Files  Layout" works properly ,but it doesn't work in "Download Details Layout".

Best Regards,
Mahdi

ColinM

Hi
I am not familiar with JsComment, it sounds useful.
Presumeably you modified your Files layout.  So could you please detail exactly what you did - preferably with the code you added. 
Thanks
Colin
Colin M
  •  

mehrabun

Hi,
Your answer did not help!
My question was exactly how to change and add it here!
Best Regards,
Mahdi

mehrabun

I Found It! for fix this bug:
please go to /public_html/components/com_jdownloads/views/download/tmpl/default.php file
and find this code: (line 390 - 397)
        $body = str_replace('{file_title}', $this->item->file_title.' '.$editIcon, $body);
        $body = str_replace('{filesize_value}', $this->item->size, $body);
        $body = str_replace('{created_by_value}', $this->item->creator, $body);   
        $body = str_replace('{modified_by_value}', $this->item->modifier, $body);
        $body = str_replace('{hits_value}',JDHelper::strToNumber((int)$this->item->downloads), $body);         
        $body = str_replace('{md5_value}',$this->item->md5_value, $body);
        $body = str_replace('{sha1_value}',$this->item->sha1_value, $body);
        $body = str_replace('{changelog_value}', $this->item->changelog, $body);
and replace with:         $body = str_replace('{file_title}', $this->item->file_title.' '.$editIcon, $body);
$body = str_replace('{file_id}', $this->item->file_id, $body);
        $body = str_replace('{filesize_value}', $this->item->size, $body);
        $body = str_replace('{created_by_value}', $this->item->creator, $body);   
        $body = str_replace('{modified_by_value}', $this->item->modifier, $body);
        $body = str_replace('{hits_value}',JDHelper::strToNumber((int)$this->item->downloads), $body);         
        $body = str_replace('{md5_value}',$this->item->md5_value, $body);
        $body = str_replace('{sha1_value}',$this->item->sha1_value, $body);
        $body = str_replace('{changelog_value}', $this->item->changelog, $body);

mehrabun

You can edit your template (html folder) for update jdownload problem:
you can create file and copy/paste from /public_html/components/com_jdownloads/views/download/tmpl/default.php file to /public_html/templates/TEMPLATENAME/html/com_jdownloads/download/default.php

ColinM

Hi
It was not obvious to me from your question that you were asking to have {file_id} support in Download Details.  Sorry for misunderstanding.
Colin
Colin M
  •