<?php
/** 
 * UQ云商：	www.uqcms.com  
 * 联系QQ：	2200631718 
 * 可免费商用，需要留UQ云商链接作为交换，只首页底部留取即可，不影响使用。
 */
  defined('IN_UQ') or exit('Access Denied'); function check_login() { if(@$_SESSION['user']['uid']){ return $_SESSION['user']['uid']; }else{ $uq0 = isset($_GET['m'])?trim($_GET['m']):'index'; $uq1 = isset($_GET['a'])?trim($_GET['a']):'index'; if($uq0 != 'member'){ location("member/login"); } } } class home extends module { function __construct() { parent::__construct(); } function index() { $this->module('user')->conn_login(); if( $this->m == 'account' || $this->m == 'address' || $this->m == 'album' || $this->m == 'order' || $this->m == 'collect' || $this->m == 'user' ){ if(empty($_SESSION['user']['uid'])){ if(cfg('wchat_status') == '1'){ if(cfg('user_conn_isbind') == '1'){ location('member/login_conn?alias=wchat'); }else{ $uq2 = cfg('request_url'); location('member/login?returnUrl='.$uq2); } }else{ $uq2 = cfg('request_url'); location('member/login?returnUrl='.$uq2); } } }else{ if(!empty($_SESSION['user']['uid'])){ if( ($this->m == 'member' && $this->a == 'login')|| ($this->m == 'member' && $this->a == 'login_conn')|| ($this->m == 'member' && $this->a == 'register')|| ($this->m == 'member' && $this->a == 'forget') ){ location('member/index'); } }else{ if(($this->m == 'member' && $this->a == 'index')){ $uq2 = cfg('request_url'); location('member/login?returnUrl='.$uq2); } } } } } 