手动安装教程

CRMEB知识付费 手动安装

1.创建数据库,倒入数据库文件
数据库文件目录/public/install/zhishifufei.sql
2.修改数据库连接文件
配置文件路径/application/database.php

// 数据库类型
'type'            => 'mysql',
// 服务器地址
'hostname'        => '127.0.0.1',
// 数据库名
'database'        => 'crmeb',
// 用户名
'username'        => 'user_crmeb',
// 密码
'password'        => 'K3YWFKYAwh1cWJrG',
// 端口
'hostport'        => '3306',
// 连接dsn
'dsn'             => '',
// 数据库连接参数
'params'          => [],
// 数据库编码默认采用utf8
'charset'         => 'utf8',
// 数据库表前缀
'prefix'          => 'eb_',
// 数据库调试模式
'debug'           => true,
// 数据库部署方式:0 集中式(单一服务器),1 分布式(主从服务器)
'deploy'          => 0,
// 数据库读写是否分离 主从式有效
'rw_separate'     => false,
// 读写分离后 主服务器数量
'master_num'      => 1,
// 指定从服务器序号
'slave_no'        => '',
// 是否严格检查字段是否存在
'fields_strict'   => false,
// 数据集返回类型
'resultset_type'  => '\\think\\Collection',
// 自动写入时间戳字段
'auto_timestamp'  => false,
// 时间字段取出后的默认时间格式
'datetime_format' => 'Y-m-d H:i:s',
// 是否需要进行SQL性能分析
'sql_explain'     => false,

3.修改目录权限(linux系统)777
/public
/runtime (缓存文件在系统运行后生成)
修改文件夹及子文件夹权限可以用命令: chmod -R 777 public

4.注释掉入口文件index.php

if(file_exists("./install/") && !file_exists("./install/install.lock")){
    if($_SERVER['PHP_SELF'] != '/index.php'){
        header("Content-type: text/html; charset=utf-8");
        exit("请在域名根目录下安装,如:<br/> www.xxx.com/index.php 正确 <br/>  www.xxx.com/www/index.php 错误,域名后面不能圈套目录, 但项目没有根目录存放限制,可以放在任意目录,apache虚拟主机配置一下即可");
    }
    header('Location:/install/index.php');
    exit();
}

5.在public/install文件夹下创建文件install.lock
6.数据库执行sql语句;选择数据库,点击sql,输入下面的sql语句,点击执行

INSERT INTO `eb_system_admin` (`id`, `account`, `pwd`, `real_name`, `roles`, `phone`, `last_ip`, `last_time`, `add_time`, `login_count`, `level`, `status`, `is_del`) VALUES (1, 'admin', 'e10adc3949ba59abbe56e057f20f883e', 'admin', '1', '', '127.0.0.1', 1694661107, 1581341252, 0, 0, 1, 0);

默认账号:admin 密码:123456

7.安装成功。
后台连接 如:http://zhishifufei.crmeb.net/admin/login/index.html
前台连接 如:http://zhishifufei.crmeb.net/wap/index/index.html
8.系统后台 设置->系统设置->基础设置 中的网站地址域名要带http或https

本页目录