返回信息流转信站: BYR!news.happynet.org!bbsnews.sdu.edu.cn!news.newsmth.net!NEWSMTH
php界面下的隐藏IP函数我用explode就搞定了
C语言的指针传递我就是搞不懂,算了晚上回来再搞
这是一条镜像帖。来源:北邮人论坛 / bbs-man-dev / #2029同步于 1 周前
BBSMan_Dev机器人发帖
telnet下的隐藏IP函数如何写?
sxdxsimple.
1 周前镜像同步5 回复
订阅后,新回复会通过你的通知中心匿名送达。
5 条回复
转信站: BYR!news.happynet.org!news.newsmth.net!NEWSMTH
site.h 定义 HAVE_OWN_USERIP 宏, 然后 site.c 里面定义
char *showuserip(struct userec *user,char *ip);
来处理...
【 在 sxdxsimple (雾里龙虾) 的大作中提到: 】
: php界面下的隐藏IP函数我用explode就搞定了
: C语言的指针传递我就是搞不懂,算了晚上回来再搞
转信站: BYR!news.happynet.org!news.cn-bbs.org!news.newsmth.net!NEWSMTH
我打算直接修改default.c
哈,发现你们的这个函数真是累赘
【 在 etnlegend (etn|金字塔·神|perplexity) 的大作中提到: 】
: site.h 定义 HAVE_OWN_USERIP 宏, 然后 site.c 里面定义
: char *showuserip(struct userec *user,char *ip);
: 来处理...
: ...................
转信站: BYR!news.happynet.org!news.uestc.edu.cn!news.newsmth.net!NEWSMTH
改了,好像没有效果,没招了
【 在 sxdxsimple (雾里龙虾) 的大作中提到: 】
: 我打算直接修改default.c
: 哈,发现你们的这个函数真是累赘
转信站: BYR!news.happynet.org!news.newsmth.net!NEWSMTH
该死...
./site/default.h:#define SHOW_USERIP(y,x) x
./site/site/default.h:#define SHOW_USERIP(y,x) x
./src/default.h:#define SHOW_USERIP(y,x) x
./libBBS/default.h:#define SHOW_USERIP(y,x) x
怪不得我改了半天没有效果...
【 在 sxdxsimple (雾里龙虾) 的大作中提到: 】
: 改了,好像没有效果,没招了
转信站: BYR!news.happynet.org!bbsnews.sdu.edu.cn!news.newsmth.net!NEWSMTH
改成SHOW_USERIP(y,x) showuserip(y,x)就好了
然后到default.c里面改
char *showuserip(struct userec *user, char *ip)
{
int length=0,out=0,count=0;
while(*ip++)
{length++;
if(*ip=='.') {count++;out=length;}
}
ip=ip-length-1;
*(ip+out+1)='*';
*(ip+out+2)='\0';
if(count==3){
return ip;
}
else return ip;
}
【 在 sxdxsimple (雾里龙虾) 的大作中提到: 】
: 该死...
: ./site/default.h:#define SHOW_USERIP(y,x) x
: ./src/default.h:#define SHOW_USERIP(y,x) x
: ...................