Hi guys,
I would like to add new button to the listing page of Jreviews component. Thats why i wrote a message to jreviews support to ask is that even possible... thats what i get back :
" Hi
You can find the solution here :
Read from the beginning of the article so you create the necessary filter file with the opening <?php tag. "
There is example for easysocial to add message button :
Examples
Add EasySocial Message Button
function add_easysocial_message_button($buttons, $params)
{
if ( !defined('ES_MESSAGE_FILTER') )
{
require_once(JPATH_ADMINISTRATOR . '/components/com_easysocial/includes/foundry.php');
ES::initialize();
ES::language()->loadSite();
define('ES_MESSAGE_FILTER', 1);
}
$listing = $params['listing'];
$easysocial = '
<button type="button" class="jrButton jrSmall"
data-es-conversations-compose=""
data-id="'.$listing['User']['user_id'].'"
data-es-provide="tooltip"
data-original-title="Contact This Member"
>
<span class="jrIconMessage"></span> Contact This Member
</button>
';
$buttons[] = $easysocial;
return $buttons;
}
Clickfwd\Hook\Filter::add('listing_detail_action_buttons', 'add_easysocial_message_button', 10);
Im not so good in php stuff... i really need that solution guys :-) can you please help me with that, i have no idea where to add this code, in which file. Maybe you can just explain me or maybe you can just add this code please