Discuz!官方免费开源建站系统

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索

[插件] 猪头诅咒术V1.0 For DZ5.5.0 发布

[复制链接]
净鬼 发表于 2007-3-30 14:01:36 | 显示全部楼层
还是有些问题...   我诅咒了别人...别人重新上传一个头像就解决了...
回复

使用道具 举报

m80 发表于 2007-3-30 14:27:48 | 显示全部楼层
感觉说明有点乱,能不能给个新的综合的说明啊。
回复

使用道具 举报

 楼主| HPotter 发表于 2007-3-30 16:08:22 | 显示全部楼层
原帖由 净鬼 于 2007-3-30 14:01 发表
还是有些问题...   我诅咒了别人...别人重新上传一个头像就解决了...


不存在你说的问题哦, 现在是被诅咒的人在自己的控制面板里看不见被诅咒的头像! 但是在个人资料和贴子里是显示被诅咒的头像! 不管任何修改都没有用的!
除非你viewthread.php和viewpro.php两个文件改的不对!
回复

使用道具 举报

kensoy 发表于 2007-3-30 19:44:26 | 显示全部楼层
感谢你的分享啊!!!
回复

使用道具 举报

qwe0253 发表于 2007-3-30 22:20:00 | 显示全部楼层
不错支持一下 :) :)
回复

使用道具 举报

12497 发表于 2007-3-31 14:08:20 | 显示全部楼层

回复 #10 sospost 的帖子

太有意思啦.哈哈.....
待用......
回复

使用道具 举报

ApLinD 发表于 2007-3-31 16:16:54 | 显示全部楼层
回复

使用道具 举报

宰宰城市 发表于 2007-4-1 15:14:24 | 显示全部楼层
有空自己要好好研究一下
回复

使用道具 举报

seekfatez 发表于 2007-4-2 17:47:02 | 显示全部楼层
Hpotter  升級安裝下完詛咒後發現他的圖沒變耶???? :Q

是否幫我看看 viewpro.php 沒改好?
謝謝先
<?php

/*
        [Discuz!] (C)2001-2007 Comsenz Inc.
        This is NOT a freeware, use is subject to license terms

        $RCSfile: viewpro.php,v $
        $Revision: 1.43.2.10 $
        $Date: 2007/03/22 22:48:51 $
*/

define('NOROBOT', TRUE);
define('CURSCRIPT', 'viewpro');
require_once './include/common.inc.php';

$uid = empty($uid) ? 0 : intval($uid);
$username = !isset($username) || $uid ? '' : $username;
$allowviewpro = $discuz_uid && ($uid == $discuz_uid || $username == $discuz_user) ? 1 : $allowviewpro;

if(!$allowviewpro) {
        showmessage('group_nopermission', NULL, 'NOPERM');
}

require_once DISCUZ_ROOT.'./include/discuzcode.func.php';
@include_once DISCUZ_ROOT.'./forumdata/cache/cache_profilefields.php';

$discuz_action = 61;

if($oltimespan) {
        $oltimeadd1 = ', o.thismonth AS thismonthol, o.total AS totalol';
        $oltimeadd2 = "LEFT JOIN {$tablepre}onlinetime o ON o.uid=m.uid";
} else {
        $oltimeadd1 = $oltimeadd2 = '';
}

$query = $db->query("SELECT m.*, mf.*, u.grouptitle, u.type, u.creditshigher, u.creditslower, u.readaccess,
                u.color AS groupcolor, u.stars AS groupstars, u.allownickname, u.allowuseblog, r.ranktitle,
                r.color AS rankcolor, r.stars AS rankstars $oltimeadd1, p.*
                FROM {$tablepre}members m
                LEFT JOIN {$tablepre}memberfields mf ON mf.uid=m.uid
                LEFT JOIN {$tablepre}usergroups u ON u.groupid=m.groupid
                LEFT JOIN {$tablepre}ranks r ON m.posts>=r.postshigher
                LEFT JOIN {$tablepre}pig p ON p.userb=m.username
                $oltimeadd2
                WHERE ".($uid ? "m.uid='$uid'" : "m.username='$username'")."ORDER BY r.postshigher DESC LIMIT 1");

if(!$member = $db->fetch_array($query)) {
        showmessage('member_nonexistence');
}

$uid = $member['uid'];
if($member['overtime'] > $timestamp + $_DCACHE['settings']['timeoffset'] * 3600) {
$member['avatar'] = 'images/pig/'.$member['type'].'.gif';
$member['avatarwidth'] = '100';
$member['avatarheight'] = '160';
}
$member['online'] = $db->result($db->query("SELECT lastactivity FROM {$tablepre}sessions WHERE uid='$uid' AND invisible='0'"), 0);

if($member['groupid'] != ($member['groupidnew'] = getgroupid($member['uid'], $member, $member))) {
        $query = $db->query("SELECT groupid, grouptitle, type, creditshigher, creditslower, color AS groupcolor,
                stars AS groupstars, allownickname, allowuseblog
                FROM {$tablepre}usergroups WHERE groupid='$member[groupidnew]'");
        $member = array_merge($member, $db->fetch_array($query));
}

$viewspace = $spacestatus && (!$supe['status'] || !$member['xspacestatus']) && !in_array($member['groupid'], array(4, 5, 6));

if($viewspace) {
        include_once DISCUZ_ROOT.'./include/space.func.php';

        //debug Space陓洘
        if(!$spacesettings = getspacesettings($member['uid'])) {
                dheader("location: $boardurl");
        }

        include_once language('spaces');

        $modulelist = explode('][', ']'.str_replace("\t", '', $spacesettings['layout']).'[');
        foreach($modulelist as $module) {
                if(array_key_exists($module, $listmodule)) {
                        $menulist[$listmodule[$module]] = $module;
                }
        }
        ksort($menulist);
}

$modforums = $comma = '';
if($member['adminid'] > 0) {
        $query = $db->query("SELECT m.fid, f.name, f.type FROM {$tablepre}moderators m, {$tablepre}forums f WHERE m.uid='$member[uid]' AND m.inherited='0' AND f.fid=m.fid");
        while($forum = $db->fetch_array($query)) {
                $modforums .= "$comma<a href=\"".($forum['type'] == 'group' ? "$indexname?gid=" : "forumdisplay.php?fid=")."$forum[fid]\">$forum[name]</a>";
                $comma = ', ';
        }
}

$member['groupterms'] = $member['groupterms'] ? unserialize($member['groupterms']) : array();

$extgrouplist = array();
if($member['extgroupids']) {
        $temp = array_map('intval', explode("\t", $member['extgroupids']));
        if($temp = implodeids($temp)) {
                $query = $db->query("SELECT groupid, grouptitle FROM {$tablepre}usergroups WHERE groupid IN ($temp)");
                while($group = $db->fetch_array($query)) {
                        $extgrouplist[] = array('title' => $group['grouptitle'], 'expiry' => (isset($member['groupterms']['ext'][$group['groupid']]) ? gmdate($dateformat, $member['groupterms']['ext'][$group['groupid']] + $timeoffset * 3600) : ''));
                }
        }
}

$query = $db->query("SELECT COUNT(*) FROM {$tablepre}posts");
@$percent = round($member['posts'] * 100 / $db->result($query, 0), 2);
$postperday = $timestamp - $member['regdate'] > 86400 ? round(86400 * $member['posts'] / ($timestamp - $member['regdate']), 2) : $member['posts'];

$member['grouptitle'] = $member['groupcolor'] ? '<font color="'.$member['groupcolor'].'">'.$member['grouptitle'].'</font>' : $member['grouptitle'];
$member['ranktitle'] = $member['rankcolor'] ? '<font color="'.$member['rankcolor'].'">'.$member['ranktitle'].'</font>' : $member['ranktitle'];

if($oltimespan) {
        $member['totalol'] = round($member['totalol'] / 60, 2);
        $member['thismonthol'] = gmdate('Yn', $member['lastactivity']) == gmdate('Yn', $timestamp) ? round($member['thismonthol'] / 60, 2) : 0;
}

$member['usernameenc'] = rawurlencode($member['username']);
$member['regdate'] = gmdate($dateformat, $member['regdate'] + $timeoffset * 3600);
$member['email'] = emailconv($member['email']);

$member['lastvisit'] = gmdate("$dateformat $timeformat", $member['lastvisit'] + ($timeoffset * 3600));
$member['lastpost'] = $member['lastpost'] ? gmdate("$dateformat $timeformat", $member['lastpost'] + ($timeoffset * 3600)) : 'x';

$member['taobaoas'] = addslashes($member['taobao']);

$member['olupgrade'] = $member['totalol'] ? 20 - $member['totalol'] % 20 : 20;

list($year, $month, $day) = explode('-', $member['bday']);
$member['bday'] = intval($year) ? $dateformat : preg_replace("/[^nj]*[Yy][^nj]*/", '', $dateformat);
$member['bday'] = str_replace('n', $month, $member['bday']);
$member['bday'] = str_replace('j', $day, $member['bday']);
$member['bday'] = str_replace('Y', $year, $member['bday']);
$member['bday'] = str_replace('y', substr($year, 2, 4), $member['bday']);

if($member['groupexpiry'] && isset($member['groupterms']['main']['time'])) {
        $member['maingroupexpiry'] = gmdate($dateformat, $member['groupterms']['main']['time'] + $timeoffset * 3600);
}

if($allowviewip && !($adminid == 2 && $member['adminid'] == 1) && !($adminid == 3 && ($member['adminid'] == 1 || $member['adminid'] == 2))) {
        require_once DISCUZ_ROOT.'./include/misc.func.php';
        $member['regiplocation'] = convertip($member['regip']);
        $member['lastiplocation'] = convertip($member['lastip']);
} else {
        $allowviewip = 0;
}

foreach(array_merge($_DCACHE['fields_required'], $_DCACHE['fields_optional']) as $field) {
        if(!$field['invisible'] || $adminid == 1 || $member['uid'] == $discuz_uid) {
                $_DCACHE['fields'][] = $field;
        }
}

unset($_DCACHE['fields_required'], $_DCACHE['fields_optional']);

if($member['medals']) {
        require_once DISCUZ_ROOT.'./forumdata/cache/cache_medals.php';
        foreach($member['medals'] = explode("\t", $member['medals']) as $key => $medalid) {
                if(isset($_DCACHE['medals'][$medalid])) {
                        $member['medals'][$key] = $_DCACHE['medals'][$medalid];
                } else {
                        unset($member['medals'][$key]);
                }
        }
}

if($viewspace) {
        include template('space');
} else {
        include template('viewpro_classic');
}

?>

[ 本帖最后由 seekfatez 于 2007-4-2 17:48 编辑 ]

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?立即注册

x
回复

使用道具 举报

 楼主| HPotter 发表于 2007-4-2 20:28:34 | 显示全部楼层

回复 #138 seekfatez 的帖子

修改的好象有点问题, 请参看2楼的最新更新再改一次!
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手机版|小黑屋|Discuz! 官方站 ( 皖ICP备16010102号 )star

GMT+8, 2024-12-23 00:34 , Processed in 0.063576 second(s), 2 queries , Gzip On, Redis On.

Powered by Discuz! X3.4

Copyright © 2001-2023, Tencent Cloud.

快速回复 返回顶部 返回列表