uc_client models user.php
function add_user($username$password$email$uid = 0, $questionid ''$answer ''$regip '') {
    $regip empty($regip) ? $this->base->onlineip : $regip;
    $salt substr(uniqid(rand()), -6);
    $password = md5(md5($password).$salt);
    $sqladd $uid "uid='".intval($uid)."'," '';
    $sqladd .= $questionid > 0 ? " secques='".$this->quescrypt($questionid$answer)."'," " secques='',";
    $this->db->query("INSERT INTO ".UC_DBTABLEPRE."members SET $sqladd username='$username', password='$password', email='$email', regip='$regip', regdate='".$this->base->time."', salt='$salt'");
    $uid $this->db->insert_id();
    $this->db->query("INSERT INTO ".UC_DBTABLEPRE."memberfields SET uid='$uid'");
    // BEGIN
    $this->db->query("INSERT INTO ".DISCUZ_DBTABLEPRE."common_member SET uid='$uid', username='$username', password='$password', email='$email', adminid='0', groupid='10', regdate='".$this->base->time."', credits='0', timeoffset='9999'");
    $this->db->query("INSERT INTO ".DISCUZ_DBTABLEPRE."common_member_status SET uid='$uid', regip='$regip', lastip='$regip', lastvisit='".$this->base->time."', lastactivity='".$this->base->time."', lastpost='0', lastsendmail='0'");
    $this->db->query("INSERT INTO ".DISCUZ_DBTABLEPRE."common_member_profile SET uid='$uid'");
    $this->db->query("INSERT INTO ".DISCUZ_DBTABLEPRE."common_member_field_forum SET uid='$uid'");
    $this->db->query("INSERT INTO ".DISCUZ_DBTABLEPRE."common_member_field_home SET uid='$uid'");
    $this->db->query("INSERT INTO ".DISCUZ_DBTABLEPRE."common_member_count SET uid='$uid', extcredits1='0', extcredits2='0', extcredits3='0', extcredits4='0', extcredits5='0', extcredits6='0', extcredits7='0', extcredits8='0'");
    // END
    return $uid;
}
 
 
 
config.inc.php中
 
define('DISCUZ_DBTABLEPRE''`discuz`.pre_');

ucenter 新增用户后 自动登录discuz 不用激活的更多相关文章

  1. Linux设置以root用户开机自动登录桌面

    目录 Ubuntu 18.04系统下设置 Redhat7.6系统下设置 Ubuntu 18.04系统下设置 1. 允许使用root用户登录桌面    Ubuntu默认不允许使用root用户登录桌面的, ...

  2. Mysql创建新用户后无法登录,提示 Access denied for user 'username'@'localhost' (using password: YES)

    MySQL创建新用户后无法登录,提示 Access denied for user 'username'@'localhost' (using password: YES) ,多半是因为存在匿名用户, ...

  3. linux启动后自动登录并运行自定义图形界面程序

    在<Ubuntu CTRL+ALT+F1~F6 进入命令模式后不支持中文显示的解决办法>一文中提到linux启动在以后运行一个独占显示器的图形程序的两种办法. 1.不启动xserver,使 ...

  4. java_web用户的自动登录模块的实现

    javaBean的代码 package bean; import java.io.Serializable; public class Admin implements Serializable{ / ...

  5. SpringBoot学习:整合shiro(rememberMe记住我后自动登录session失效解决办法)

    项目下载地址:http://download.csdn.NET/detail/aqsunkai/9805821 定义一个拦截器,判断用户是通过记住我登录时,查询数据库后台自动登录,同时把用户放入ses ...

  6. 【转载】CentOS 7自动以root身份登录gnome桌面 操作系统开机后自动登录到桌面 跳过GDM

    CentOS 7自动以root身份登录gnome桌面 ################### #cd /etc/gdm ]# cat custom.conf# GDM configuration st ...

  7. win7用户账户自动登录方法

    为了计算机安全,相信使用Windows7系统的朋友大多都为自己的用户账户设置了或简单或复杂的密码,其实对于个人电脑来说,开机登录输入密码有时候会显得累赘,毕竟用户账户密码不仅仅是为了防止他人登录. 那 ...

  8. mate桌面用户 root 自动登录lightdm.conf -20190520 方法【fedora 21】mate

    桌面用户自动登录lightdm.conf -20190520 方法修改 /etc/lightdm/lightdm.conf 步骤:1 vim  /etc/lightdm/lightdm.conf 解除 ...

  9. 如何让用户登录Dynamics 365 Customer Engagement后自动登录到Unified Interface App?

    微软动态CRM专家罗勇 ,回复324或者20190422可方便获取本文,同时可以在第一间得到我发布的最新博文信息,follow me! Dynamics 365 Customer Engagement ...

随机推荐

  1. 用Charles抓取https接口数据

    由于我之前抓取的某APP接口全面换上了https接口,导致我在抓取过程中遇到了很大的困境 用Charles无法获取到内容,由于现在已经搞定了,无法展示当时的错误信息,我从网站找了一个类似的错误信息 首 ...

  2. angularjs指令系统系列课程(5):控制器controller

    这一节我们来说一下controller这个参数 一.指令控制器的配置方法: 对于指令我有两种配置路由的方式:1.在html中直接引用,2,在指令的controller参数里定义 第一种:在html中直 ...

  3. function方法中this的用法

    jsp<select class="mokuai2" onchange="Mokuai2Change(this.value)"></selec ...

  4. 使用layer.open时content属性传值记录

    最近在做一个后台项目,正好碰上了要使用layer.open,就顺手记录一下,方便以后遇到了有个参考 - 2016/11/7 layer 这个是一个web弹层组件,挺好用的...然后项目框架是SSM.. ...

  5. 12 个CSS 高级技巧汇总[转载]

    使用 :not() 在菜单上应用/取消应用边框 给body添加行高 所有一切都垂直居中 逗号分隔的列表 使用负的 nth-child 选择项目 对图标使用SVG 优化显示文本 对纯CSS滑块使用 ma ...

  6. Caché数据库学习笔记(5)

    目录 Cache数据库方法的RESTful封装 ================================================================ 因为对web serv ...

  7. 遇到 java.io.EOFException 异常的解决办法

    可以试着clean项目后再启动!原因未明

  8. Linux下如何修改Apache根目录

    创建自己需要更改的新目录,并更改宿主权限为apache用户 chown -R apache:apache /mnt/www   停止Apache服务 service httpd stop 3 修改Ap ...

  9. NGUI制作属于自己Button

    1.收集一些PNG或PSD格式的button按钮图片(放在img文件夹下,全选) 2.选择需要制作button的图片,NGUI--Atlas Maker--Create,会出现三个命名一样的东西,1个 ...

  10. C++中的const和指针组合

    在C++里,const修饰指针有以下三种情况 (1)指针常量:即指向常量的指针 const  int *p或者int const *p const在*前,,可以这样理解它的功能,因为const在*前, ...