LEP3.3开源-售卖.zip
26.3 M
零度LEP3.3分销系统开源来啦~仅供学习研究,请勿倒卖等可耻行为。
若侵犯了作者的权益请私信我。550090076@qq.com
零度LEP分销系统-已更新至3.3版本-自主开发-全网领先
1.全新采用Thinkphp框架开发,全网首发
2.拥有对接全网EP分销的功能【对接云屋没毛病】
3 .前台后台全新UI 拒绝EPD传统UI
4.微博QQ登录 方便快捷
5.邮箱注册,手机号注册[暂未开放]
6.该有的多有 懒得写了
1.1版本更新记录:
1.后台在线更新,无需手动替换文件
2.EPD数据库一键转换LEP数据库
3.测试站功能,修改信息后自动发送给站长
4.该有的都有了 懒得写了
安装新网站程序
1.域名需要授权才可以使用.
2.php版本需要sg11插件才可正常运行.
3.如有不懂问题,请联系上级.
4.程序使用PHP7.3版本运行.
5.正确的迁移步骤:备份程序和数据库->迁移恢复->修改config.php数据库连接文件.
6.程序出现异常请按照以下顺序依次打开测试站进行测试,如果官方测试站也有此问题,可以联系官方进行纠错问题.
7.程序需使用伪静态,如果不使用一些页面将会出现404,apache自动识别伪静态,nginx请使用Apache转Nginx.
安装包截图
全部解密 开源版本
下面是LEP\Common\Common/function.php 代码示例
<?php define('VERSION', '3.3'); define('AUTH_URL', 'http://apis.nitianidc.com/'); define('AUTH_API_URL', 'http://apis.nitianidc.com/api.php'); function admin_log($remark) { $data = [ 'admin_id' => session('adminuser'), 'ip' => ip(), 'remark' => $remark, 'create_time' => date('Y-m-d H:i:s') ]; M('adminLog')->add($data); } function getkmkey($len = 16) { $str = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789'; $strlen = strlen($str); $randstr = ''; for ($i = 0; $i < $len; $i++) { $randstr .= $str[mt_rand(0, $strlen - 1)]; } return $randstr; } /** * 获取文件夹 * @param $dir * @return array */ function getFloder($dir) { $files = array(); if ($head = opendir($dir)) { while (($file = readdir($head)) !== false) { if ($file != ".." && $file != ".") { if (is_dir($file)) { $files[$file] = bianli1($dir . '/' . $file); } else { $files[] = $file; } } } } closedir($head); return $files; } function ip() { if (getenv('HTTP_CLIENT_IP') && strcasecmp(getenv('HTTP_CLIENT_IP'), 'unknown')) { $ip = getenv('HTTP_CLIENT_IP'); } elseif (getenv('HTTP_X_FORWARDED_FOR') && strcasecmp(getenv('HTTP_X_FORWARDED_FOR'), 'unknown')) { $ip = getenv('HTTP_X_FORWARDED_FOR'); } elseif (getenv('REMOTE_ADDR') && strcasecmp(getenv('REMOTE_ADDR'), 'unknown')) { $ip = getenv('REMOTE_ADDR'); } elseif (isset($_SERVER['REMOTE_ADDR']) && $_SERVER['REMOTE_ADDR'] && strcasecmp($_SERVER['REMOTE_ADDR'], 'unknown')) { $ip = $_SERVER['REMOTE_ADDR']; } return preg_match ('/[\d\.]{7,15}/', $ip, $matches) ? $matches [0] : ''; } function request_post($url = '', $post_data = array()) { if (empty($url) || empty($post_data)) { return false; } $o = ""; foreach ($post_data as $k => $v) { $o.= "$k=" . urlencode($v). "&" ; } $post_data = substr($o,0,-1); $postUrl = $url; $curlPost = $post_data; $ch = curl_init(); //初始化curl curl_setopt($ch, CURLOPT_URL,$postUrl); //抓取指定网页 curl_setopt($ch, CURLOPT_HEADER, 0); //设置header curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); //要求结果为字符串且输出到屏幕上 curl_setopt($ch, CURLOPT_POST, 1); //post提交方式 curl_setopt($ch, CURLOPT_POSTFIELDS, $curlPost); $data = curl_exec($ch); //运行curl curl_close($ch); return $data; } function robotLogin ($redirect) { $url = $_SERVER['HTTP_HOST']; $url = 'https://auth.nitianidc.com/Robot/index.html?url=' . $url . '&redirect_uri=' . $redirect; return $url; } function qqLogin ($redirect) { $loginType = 'qqlogin'; $state = md5(uniqid().mt_rand()); $_SESSION['state'] = $state; $url = 'https://api.nitianidc.com/Oauth/request.api?state=' . $state . '&type=' . $loginType . '&redirect_uri=' . $redirect; return $url; } function wxLogin ($redirect) { $url = $_SERVER['HTTP_HOST']; $url = 'https://auth.nitianidc.com/wx/index.html?url=' . $url . '&redirect_uri=' . $redirect; return $url; } function wbLogin ($redirect) { $loginType = 'wblogin'; $state = md5(uniqid().mt_rand()); $_SESSION['state'] = $state; $url = 'https://cloud.qqlogin.com/Oauth/request.api?state=' . $state . '&type=' . $loginType . '&redirect_uri=' . $redirect; return $url; } function wxts ($title,$content,$openid) { if (!empty($openid)) { $ssl = $_SERVER['SERVER_PORT'] == '443' ? 'https://' : 'http://' ; $url = $ssl . $_SERVER['SERVER_NAME']; file_get_contents('http://xauth.nitianidc.com/wx/mbone?url='.$url.'&title='.$title.'&openid='.$openid.'&content='.$content); $user = M('user')->where(array('userwx' => $openid))->find(); if (strpos($user['usersjh'],'@') !== false) { $web = M('config')->where(array('id' => 1))->find(); if ($web['mail_type'] == 1) { file_get_contents("http://api.nitianidc.com/Request/send_mailb.api?to={$user['usersjh']}&nick={$web['webname']}&title={$title}&content={$content}"); } else { file_get_contents("http://api.nitianidc.com/Request/send_mailsb.api?to={$user['usersjh']}&nick={$web['webname']}&title={$title}&content={$content}&smtp={$web['mail_smtp']}&name={$web['mail_name']}&pwd={$web['mail_pwd']}&port={$web['mail_port']}"); } } } return true; } function apiState($ip, $key, $url) { return json_decode(file_get_contents(AUTH_URL . 'api.php?act=apistatus&ip='.$ip.'&key='.$key.'&url='.$url), TRUE); } function random_str () { $poems = "primary success info warning danger purple cyan brown"; $poems = explode("\n",$poems); return $poems[rand(0,count($poems)-1)]; } function json($code, $msg = NULL, $data = array()) { $jsonData = array( 'code' => $code, 'msg' => $msg, 'data' => $data ); exit(json_encode($jsonData)); } function getcloud($url, $data) { foreach ($data as $k => $v) { $url .= '&' . $k . '=' . $v; } return json_decode(file_get_contents($url), TRUE); } function createurl($apiip, $apikey, $type) { $ip = $apiip; $key = $apikey; $c = 'whm'; $a = $type; $r = rand(100000,999999); $json = '1'; $s = md5($a.$key.$r); $url = "http://$ip:3312/api/index.php?c=$c&a=$a&r=$r&json=$json&s=$s"; return $url; } function apiinfo($ip, $key) { $c = 'whm'; $a = 'info'; $r = rand(100000,999999); $json = '1'; $s = md5($a.$key.$r); $url = "http://$ip:3312/api/index.php?c=$c&a=$a&r=$r&json=$json&s=$s"; $clouddata = json_decode(file_get_contents($url), TRUE); $data = array(); foreach ($clouddata as $k => $v) { if (is_array($v)) { $data[$k] = $v['0']['0']; } else { $data[$k] = $v; } } return $data; } function terminateaccount($apiip, $apikey, $data) { $url = createurl($apiip, $apikey, 'del_vh'); $data = array( 'name' => $data['hostname'] ); $data = getcloud($url, $data); return $data; } function createaccount($apiip, $apikey, $dpata) { $url = createurl($apiip, $apikey, 'add_vh'); $data = array( "name" => $dpata['hostname'], "passwd" => $dpata['hostpwd'], 'web_quota' => $dpata['hostlimit'], 'db_quota' => $dpata['dblimit'], 'vhost_domains' => $dpata['hostdomain'], 'domain' => $dpata['domainlimit'], 'max_subdir' => $dpata['dirlimit'], 'flow_limit' => $dpata['flowlimit'], 'subdir_flag' => '1', 'ftp' => '1', 'max_connect' => '0', 'speed_limit' => '0', 'db_type' => 'mysql', 'module' => 'php', 'max_worker' => '0', 'subdir' => 'wwwroot', 'log_file' => '1', 'htaccess' => '1', 'access' => '1', 'cdn' => $dpata['hosttype'], 'port' => $dpata['oport'] ); $data = getcloud($url, $data); return $data; } function suspendaccount($apiip, $apikey, $data) { $url = createurl($apiip, $apikey, 'update_vh'); $data = array( 'name' => $data['hostname'], 'status' => $data['hoststate'] ); $data = getcloud($url, $data); return $data; } function changepassword($apiip, $apikey, $data) { $url = createurl($apiip, $apikey, 'change_password'); $data = array( 'name' => $data['hostname'], 'passwd' => $data['hostpwd'] ); $data = getcloud($url, $data); return $data; } function diskSizeMb($num) { return intval($num/1024/1024); } function onlineUpdate($fileLink, $fileRoute, $dirName) { if (!class_exists('ZipArchive'))$this->error('不支持在线更新', '/admin',3); copy($fileLink, $fileRoute) or $this->error('无法下载更新包文件', '/admin',3); $ZipArchive = new ZipArchive(); if ($ZipArchive->open($fileRoute)) { $ZipArchive->extractTo($dirName); $ZipArchive->close(); unlink($fileRoute); return true; } return false; } //删除文件夹以及全部文件 function deldir($dir) { //先删除目录下的文件: $dh = opendir($dir); while ($file = readdir($dh)) { if ($file != "." && $file != "..") { $fullpath = $dir."/".$file; if (!is_dir($fullpath)) { unlink($fullpath); } else { deldir($fullpath); } } } closedir($dh); //删除当前文件夹: if (rmdir($dir)) { return true; } else { return false; } } ?>
关于QQ登录失效 可以换成我的接口
function qqLogin ($redirect) { $loginType = 'qqlogin'; $state = md5(uniqid().mt_rand()); $_SESSION['state'] = $state; $url = 'https://api.nitianidc.com/Oauth/request.api?state=' . $state . '&type=' . $loginType . '&redirect_uri=' . $redirect; return $url;
https://api.nitianidc.com/Oauth/request.api?state=
域名换成下面的即可
https://qqlogin.wenytao.com/Oauth/request.api?state=
[CommentView]
https://vience.lanzoui.com/iO6lsrkphva
[/CommentView]
[Bomb]