Hi,
I wanted to delete Friends and Groups modules from the profile cover.
I found one of the replies that recommended the following:
"Make override file for the template: documentation.jomsocial.com/wiki/Customizing_Template
make override file for:
components/com_community/templates/default/profile.firends.php
components/com_community/templates/default/profile.groups.php
components/com_community/templates/default/profile.index.php
override for profile.firends.php and profile.groups.php delete all code at there, so it will empty file.and override for profile.index.php, edit line 35:
from:
<div class="span8">
to
div class="span12">"
I have done so but the Friends and Groups are still visible on the menu just below the Profile cover.
My override files are created in ROOT/templates/MyTemplateName/html/com_community
Thanks.
Am I missing something from the above instructions?
In order to remove those links you'll need to edit this file:
ROOT/components/com_community/templates/default/modules/profile/userinfo.php
(WARNING! Core file hack! Please, make safe copy of edited file. It means also that this file will be overwritten during upgrade, so please make a safe copy of customized file as well.)
Links are in UL and this element starts from line 77. You should be interested in lines: 94 and 107.
Hi,
I tried your solution and deleted the code:
<?php }?>
<?php if($groupEnabled) {?>
<li>
<a href="<?php echo CRoute::_('index.php?option=com_community&view=groups&task=mygroups&userid='.$profile->id); ?>">
<?php echo ($profile->_groups == 1) ? JText::sprintf('COM_COMMUNITY_GROUPS_COUNT',$profile->_groups) : JText::sprintf('COM_COMMUNITY_GROUPS_COUNT_MANY',$profile->_groups) ?>
</a>
</li>
but it didn't work.
Hi.
This solution works 100% :)
Just remove code carefully.
Like I said, the solution is not working.
Are these the codes to remove to get rid of the Group module?
HI Jomsocial Newbie,
Lets see if we can get this working for you. There are a few ways to do it but this way should be quite simple
Open the file siteroot/components/com_community/templates/default/profile.index.php
then find the following code around line 68
<!-- begin: .cSidebar -->
<div class="cSidebar">
<?php
$this->renderModules( 'js_side_top' );
$this->renderModules( 'js_profile_side_top' );
echo $sidebarTop;
if($isMine) $this->renderModules( 'js_profile_mine_side_top' );
echo $this->view('profile')->modProfileUserVideo();
echo $this->view('profile')->modGetFriendsHTML();
if( $config->get('enablegroups')){
echo $this->view('profile')->modGetGroupsHTML();
}
if($isMine) $this->renderModules( 'js_profile_mine_side_bottom' );
echo $sidebarBottom;
$this->renderModules( 'js_profile_side_bottom' );
$this->renderModules( 'js_side_bottom' );
?>
</div>
<!-- end: .cSidebar -->
// echo $this->view('profile')->modGetFriendsHTML();
// echo $this->view('profile')->modGetGroupsHTML();
<div class="row-fluid">
<div class="span8">
<!-- begin: .cMain -->
<div class="cMain">
<?php $this->renderModules( 'js_profile_feed_top' ); ?>
<div class="activity-stream-front">
<div class="row-fluid">
<div class="span12">
<!-- begin: .cMain -->
<div class="cMain">
<?php $this->renderModules( 'js_profile_feed_top' ); ?>
<div class="activity-stream-front">
Thank you very much, Paul.
This solution works.
Have a great day ahead.