项目论坛项目前准备工作 1.需求分析 参考discuz开源产品 discuz产品安装后 下一步...需要将数据库用户名密码输入正确 添加一个管理员账号 记住用来登录网站后台的 之后完成 问题: 访问首页没有样式 地址栏输入admin.php 进入后台 工具选项 更新缓存 报错 缺少参数 按报错找到文件指定行将参数加进去 true 再更新缓存 重新访问即可
BUG 用户管理 详情有问题
2.需求分析表 按需求分析表 给大家演示对应模块 需要大家明确需求
3.按需求表进行数据库设计 参考数据字典
4.开始项目 项目使用框架 先将结构搭建出来
5.TP中使用命令行生成目录 需要将php.exe加入到环境变量中
6.开发时编辑器 建议使用sublime 将整个项目放进去 方便查找 也可以使用快捷方式ctrl+p找到指定文件进行编辑
7.解压tp5.1压缩包 到根目录TP5.1的入口文件为:D:\xampp\htdocs\mydiscuz\public\index.php
进行虚拟主机配置(linux位置讲)
apache配置文件中 D:\xampp\apache\conf
确认下面的是打开的
# Virtual hosts
Include conf/extra/httpd-vhosts.conf
按包含地址找到文件使用编辑器打开进行如下配置
<VirtualHost *:80>
ServerAdmin webmaster@dummy-host2.example.com
DocumentRoot "D:\xampp\htdocs\mydiscuz\public"
ServerName www.mydiscuz.com
ErrorLog "logs/dummy-host2.example.com-error.log"
CustomLog "logs/dummy-host2.example.com-access.log" common
</VirtualHost>
<VirtualHost *:80>
ServerAdmin webmaster@dummy-host2.example.com
DocumentRoot "D:\xampp\htdocs"
ServerName localhost
ErrorLog "logs/dummy-host2.example.com-error.log"
CustomLog "logs/dummy-host2.example.com-access.log" common
</VirtualHost>
将DNS域名解析中 先找本机hosts文件 所以在hosts中进行配置
C:\Windows\System32\drivers\etc\hosts
# Copyright (c) 1993-2009 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
# 102.54.94.97 rhino.acme.com # source server
# 38.25.63.10 x.acme.com # x client host
# localhost name resolution is handled within DNS itself.
# 127.0.0.1 localh