參考連結: http://phpbb-tw.net/phpbb/viewtopic.php?t=20786
使用版本:phpBB 2.0.8a
網站位置:http://members.lycos.co.uk/m43q/phpbb/
狀況描述:
我裝了水怪完整版後,想進去卻出現這個訊息:
Fatal error: Cannot redeclare getavatar() (previously declared in /data/members/free/tripod/uk/m/4/3/m43q/htdocs/phpbb/rpg/function_rpg.php:9) in /data/members/free/tripod/uk/m/4/3/m43q/htdocs/phpbb/rpg/function_rpg.php on line 9
請問,這個訊息是什麼意思?是說讀不到圖片嗎?
還是無法讀兩次?不太懂
我查了下rpg/function_rpg.php的原始碼第9行是:
代碼: 選擇全部
function GetAvatar($profiledata)
{
global $board_config;
$avatar_img = '';
if ( $profiledata['user_avatar_type'] && $profiledata['user_allowavatar'] )
{
switch( $profiledata['user_avatar_type'] )
{
case USER_AVATAR_UPLOAD:
$avatar_img = ( $board_config['allow_avatar_upload'] ) ? '<img src="' . $board_config['avatar_path'] . '/' . $profiledata['user_avatar'] . '" border="0" />' : '';
break;
case USER_AVATAR_REMOTE:
$avatar_img = ( $board_config['allow_avatar_remote'] ) ? '<img src="' . $profiledata['user_avatar'] . '" border="0" />' : '';
break;
case USER_AVATAR_GALLERY:
$avatar_img = ( $board_config['allow_avatar_local'] ) ? '<img src="' . $board_config['avatar_gallery_path'] . '/' . $profiledata['user_avatar'] . '" border="0" />' : '';
break;
}
}
if ($profiledata['user_robfail'] > 0)
{
$avatar_img .= '<br />';
$robid = floor(($profiledata['user_robfail'] - 1) / 4);
$robcnt = (($profiledata['user_robfail'] - 1) % 4) + 1;
if ($robid <= 7)
{
for ($i=0; $i < $robcnt; $i++)
{
$avatar_img .= '<img src="images/rob' . $robid . '.gif" />';
}
}
else
{
$avatar_img .= '<img src="images/rob7.gif" />× ' . ($profiledata['user_robfail'] - 28);
}
$avatar_img .= '<br /><span class="gensmall">笨!失敗的搶匪</span>';
}
return $avatar_img;
}是說讀不到profiledata?還是有讀過,而無法再讀一次?
望請各位前輩教導
