$view[name] 이파일 어디서 수정해야하는지요?
본문
view_skin.php. 파일에 $view[name] 이부분을 클릭하면, 쪽지보내기, 회원정보변경등 나오는데요.
이거 수정할려면, 어떤파일을 보아야 하는지요??
답변 1
/lib/common.lib.php 파일의 1195~1282 라인 근처를 보시면 get_sideview 함수가 보이실 거예요.
해당 함수의 내부 코드를 수정하시면 됩니다.(아래 참조)
=====================================================================================
// 회원 레이어
function get_sideview($mb_id, $name='', $email='', $homepage='')
{
global $config;
global $g5;
global $bo_table, $sca, $is_admin, $member;
$email = base64_encode($email);
$homepage = set_http(clean_xss_tags($homepage));
$name = preg_replace("/\'/", "", $name);
$name = preg_replace("/\'/", "", $name);
$name = preg_replace("/\"/", """, $name);
$title_name = $name;
$tmp_name = "";
if ($mb_id) {
//$tmp_name = "<a href=\"".G5_BBS_URL."/profile.php?mb_id=".$mb_id."\" class=\"sv_member\" title=\"$name 자기소개\" target=\"_blank\" onclick=\"return false;\">$name</a>";
$tmp_name = '<a href="'.G5_BBS_URL.'/profile.php?mb_id='.$mb_id.'" class="sv_member" title="'.$name.' 자기소개" target="_blank" onclick="return false;">';
if ($config['cf_use_member_icon']) {
$mb_dir = substr($mb_id,0,2);
$icon_file = G5_DATA_PATH.'/member/'.$mb_dir.'/'.$mb_id.'.gif';
if (file_exists($icon_file)) {
$width = $config['cf_member_icon_width'];
$height = $config['cf_member_icon_height'];
$icon_file_url = G5_DATA_URL.'/member/'.$mb_dir.'/'.$mb_id.'.gif';
$tmp_name .= '<img src="'.$icon_file_url.'" width="'.$width.'" height="'.$height.'" alt="">';
if ($config['cf_use_member_icon'] == 2) // 회원아이콘+이름
$tmp_name = $tmp_name.' '.$name;
} else {
$tmp_name = $tmp_name." ".$name;
}
} else {
$tmp_name = $tmp_name.' '.$name;
}
$tmp_name .= '</a>';
$title_mb_id = '['.$mb_id.']';
} else {
if(!$bo_table)
return $name;
$tmp_name = '<a href="'.G5_BBS_URL.'/board.php?bo_table='.$bo_table.'&sca='.$sca.'&sfl=wr_name,1&stx='.$name.'" title="'.$name.' 이름으로 검색" class="sv_guest" onclick="return false;">'.$name.'</a>';
$title_mb_id = '[비회원]';
}
$name = get_text($name);
$email = get_text($email);
$homepage = get_text($homepage);
$str = "<span class=\"sv_wrap\">\n";
$str .= $tmp_name."\n";
$str2 = "<span class=\"sv\">\n";
if($mb_id)
$str2 .= "<a href=\"".G5_BBS_URL."/memo_form.php?me_recv_mb_id=".$mb_id."\" onclick=\"win_memo(this.href); return false;\">쪽지보내기</a>\n";
if($email)
$str2 .= "<a href=\"".G5_BBS_URL."/formmail.php?mb_id=".$mb_id."&name=".urlencode($name)."&email=".$email."\" onclick=\"win_email(this.href); return false;\">메일보내기</a>\n";
if($homepage)
$str2 .= "<a href=\"".$homepage."\" target=\"_blank\">홈페이지</a>\n";
if($mb_id)
$str2 .= "<a href=\"".G5_BBS_URL."/profile.php?mb_id=".$mb_id."\" onclick=\"win_profile(this.href); return false;\">자기소개</a>\n";
if($bo_table) {
if($mb_id)
$str2 .= "<a href=\"".G5_BBS_URL."/board.php?bo_table=".$bo_table."&sca=".$sca."&sfl=mb_id,1&stx=".$mb_id."\">아이디로 검색</a>\n";
else
$str2 .= "<a href=\"".G5_BBS_URL."/board.php?bo_table=".$bo_table."&sca=".$sca."&sfl=wr_name,1&stx=".$name."\">이름으로 검색</a>\n";
}
if($mb_id)
$str2 .= "<a href=\"".G5_BBS_URL."/new.php?mb_id=".$mb_id."\">전체게시물</a>\n";
if($g5['sms5_use_sideview']){
$mb = get_member($mb_id, " mb_open, mb_sms , mb_hp ");
if( $mb['mb_open'] && $mb['mb_sms'] && $mb['mb_hp'] ) $str2 .= "<a href=\"".G5_SMS5_URL."/?mb_id=".$mb_id."\" class=\"win_sms5\" target=\"_blank\">문자보내기</a>\n";
}
if($is_admin == "super" && $mb_id) {
$str2 .= "<a href=\"".G5_ADMIN_URL."/member_form.php?w=u&mb_id=".$mb_id."\" target=\"_blank\">회원정보변경</a>\n";
$str2 .= "<a href=\"".G5_ADMIN_URL."/point_list.php?sfl=mb_id&stx=".$mb_id."\" target=\"_blank\">포인트내역</a>\n";
}
$str2 .= "</span>\n";
$str .= $str2;
$str .= "\n<noscript class=\"sv_nojs\">".$str2."</noscript>";
$str .= "</span>";
return $str;
}