用平安充值积分链接boan_buycredit:buycredit替换系统自带充值op=buy链接的nginx重定向方法分享:
修改插件文件方式添加:
if(CURSCRIPT=='home' && $_GET['mod']=='spacecp' && $_GET['ac']=='credit' && $_GET['op']=='buy' ){
dheader('location: home.php?mod=spacecp&ac=plugin&op=credit&id=boan_buycredit:buycredit');
}
另外,最简单方法:
nginx伪静态规则302跳转的方法:
置于伪静态规则的第二行起:
if ($request_uri ~* 'op=buy'){
return 302 home.php?mod=spacecp&ac=plugin&op=credit&id=boan_buycredit:buycredit;
}
|