Hi Guys,
for complete integration of jomsocial please:
1.: set in configuration of com_resource "Community Integration" to "com_comprofiler"
2.: hack the com_comprofiler.php file (.../components/com_resource/library/php/community/com_comprofiler.php)
<?php defined('_JEXEC') or die('Restricted access'); ?>
<?php
class MRCommunityCom_comprofiler
{
function userName($id, $name)
{
$jspath = JPATH_BASE.DS.'components'.DS.'com_community';
include_once($jspath.DS.'libraries'.DS.'core.php');
$user_profile_link = CRoute::_("index.php?option=com_community&view=profile&userid={$id}");
$out = JHTML::link($user_profile_link, $name);
return $out;
}
function userAvatar($id, $params, $prefix = '')
{
$db =&JFactory::getDBO();
static $users = array();
if(array_key_exists($id, $users)) return $users[$id];
$sql = "SELECT avatar FROM #__community_users WHERE userid = ".$id." AND avatarapproved = 1";
$db->setQuery($sql);
$fname = $db->loadResult();
if($fname)
{
$avatar = '<a href="'. $link .'">'.JHTML::image(JURI::base().''.$fname, $user->get('username'). JText::_('Avatar')).'</a>';
return $users[$id];
}
else
{
$users[$id] = JHTML::image(JURI::base().'components/com_community/assets/user_thumb.png', JText::_('Avatar'));
return $users[$id];
}
}
}
?>
3.: have fun!
cheers Jan
Special



Profile of pdmunich
Add a Friend
All User Extensions (3)
Send Message 
+1 (209) 800 1209