묻고답하기
page_full_width" class="col-xs-12" |cond="$__Context->page_full_width">
회원정보보기를 관리자만 볼수있게 할 수는 없나요?
2014.09.23 19:48
전체 익명홈인데
출석체크만 닉네임 노출되게해놔서 따로 신경을 안써서 몰랐는데
오늘 닉네임 눌러보니 회원정보 보기가 뜨고 상세 아이디/메일주소등을 일반회원도 다 볼 수 있더라구요
아이디나 메일주소는 다 관리자만 볼 수 있게하고싶은데
어디서 설정을 해야하는지ㅠ_ㅠ
댓글 3
-
Bryan!
2014.09.23 19:55
-
혜민2
2014.09.25 00:28
이대로 교체했더니 597라인에 에러있다면서 안먹혀요ㅠㅠ..
-
Bryan!
2014.09.25 16:15
첨부한 압축화일을 풀어서 덮어씌워보세요. 참고로 버전은 1.7.7.1 최신 입니다.
/modules/member/member.model.php 에서 다음 내용 수정.
/**
* @brief Display menus of the member
*/
function getMemberMenu()
{
$logged_info = Context::get('logged_info');
if($logged_info->is_admin == 'Y'){
// Get member_srl of he target member and logged info of the current user
$member_srl = Context::get('target_srl');
$mid = Context::get('cur_mid');
$logged_info = Context::get('logged_info');
$act = Context::get('cur_act');
// When click user's own nickname
if($member_srl == $logged_info->member_srl) $member_info = $logged_info;
// When click other's nickname
else $member_info = $this->getMemberInfoByMemberSrl($member_srl);
$member_srl = $member_info->member_srl;
if(!$member_srl) return;
// List variables
$user_id = $member_info->user_id;
$user_name = $member_info->user_name;
ModuleHandler::triggerCall('member.getMemberMenu', 'before', $null);
$oMemberController = getController('member');
// Display member information (Don't display to non-logged user)
if($logged_info->member_srl)
{
$url = getUrl('','mid',$mid,'act','dispMemberInfo','member_srl',$member_srl);
$oMemberController->addMemberPopupMenu($url,'cmd_view_member_info',$icon_path,'self');
}
// When click other's nickname
if($member_srl != $logged_info->member_srl && $logged_info->member_srl)
{
// Send an email
if($member_info->email_address)
{
$url = 'mailto:'.htmlspecialchars($member_info->email_address, ENT_COMPAT | ENT_HTML401, 'UTF-8', false);
$oMemberController->addMemberPopupMenu($url,'cmd_send_email',$icon_path);
}
}
// View homepage info
if($member_info->homepage)
$oMemberController->addMemberPopupMenu(htmlspecialchars($member_info->homepage, ENT_COMPAT | ENT_HTML401, 'UTF-8', false), 'homepage', '', 'blank');
// View blog info
if($member_info->blog)
$oMemberController->addMemberPopupMenu(htmlspecialchars($member_info->blog, ENT_COMPAT | ENT_HTML401, 'UTF-8', false), 'blog', '', 'blank');
// Call a trigger (after)
ModuleHandler::triggerCall('member.getMemberMenu', 'after', $null);
// Display a menu for editting member info to a top administrator
if($logged_info->is_admin == 'Y')
{
$url = getUrl('','module','admin','act','dispMemberAdminInsert','member_srl',$member_srl);
$oMemberController->addMemberPopupMenu($url,'cmd_manage_member_info',$icon_path,'MemberModifyInfo');
$url = getUrl('','module','admin','act','dispDocumentAdminList','search_target','member_srl','search_keyword',$member_srl);
$oMemberController->addMemberPopupMenu($url,'cmd_trace_document',$icon_path,'TraceMemberDocument');
$url = getUrl('','module','admin','act','dispCommentAdminList','search_target','member_srl','search_keyword',$member_srl);
$oMemberController->addMemberPopupMenu($url,'cmd_trace_comment',$icon_path,'TraceMemberComment');
}
// Change a language of pop-up menu
$menus = Context::get('member_popup_menu_list');
$menus_count = count($menus);
for($i=0;$i<$menus_count;$i++)
{
$menus[$i]->str = Context::getLang($menus[$i]->str);
}
// Get a list of finalized pop-up menu
$this->add('menus', $menus);
}
}