PHP课程设计报告材料4Word下载.docx

上传人:b****6 文档编号:18579846 上传时间:2022-12-28 格式:DOCX 页数:30 大小:644.31KB
下载 相关 举报
PHP课程设计报告材料4Word下载.docx_第1页
第1页 / 共30页
PHP课程设计报告材料4Word下载.docx_第2页
第2页 / 共30页
PHP课程设计报告材料4Word下载.docx_第3页
第3页 / 共30页
PHP课程设计报告材料4Word下载.docx_第4页
第4页 / 共30页
PHP课程设计报告材料4Word下载.docx_第5页
第5页 / 共30页
点击查看更多>>
下载资源
资源描述

PHP课程设计报告材料4Word下载.docx

《PHP课程设计报告材料4Word下载.docx》由会员分享,可在线阅读,更多相关《PHP课程设计报告材料4Word下载.docx(30页珍藏版)》请在冰豆网上搜索。

PHP课程设计报告材料4Word下载.docx

所以,本系统在经济上是可行的。

1.2.2技术可行性

本系统的开发利用MySQL作为本系统的数据库,它是一个支持多用户的新型数据库,适用于大中规模的数据量需求。

学校校园网的建设也为新系统服务器/客户端的结构提供了硬件的支持。

使用wamp与navicat作为系统开发的开发环境,它提供完善的指令控制语句、类与对象的支持及丰富的数据类型,给开发高性能系统提供的保障为开发满足客户要求的系统,保证了代码的模块化要求,而代码模块化的提高,非常有利于以后对新系统的扩展与修改。

1.2.3操作可行性

本系统为一个小型的学生信息管理系统,所耗费的资源非常的小,学校的电脑无论是硬件还是软件都能够满足条件,界面设计时充分考虑管理人员的习惯,使得操作简单;

数据录入迅速、规范、可靠;

统计准确;

制表灵活;

适应力强;

容易扩充,因此,本系统在操作上是可行的

2.数据库逻辑结构设计

2.2.1数据库E-R图

2.2.2数据库关系模式:

Administrator(AdminID,AdminName,AdminPassword);

ClassInfo(Class,Major,department)

CourseInfo(CourseNumber,CourseName,Grade);

StudentCourse(StudentID,CourseNumber,Marks);

StudentInfo(StudentID,StudentName,Class,StudentPassword);

TeacherInfo(TeacherID,TeacherName,TeacherPassword);

TeachingInfo(CourseNumber,TeacherID);

数据库名称:

management

拥有的表:

administrator;

Classinfo;

Courseinfo;

StudentCourse;

Studentinfo;

Teacherinfo;

Teachinginfo;

各个表的属性及数据:

Administrator(AdminIDchar(20)primarykey,,AdminNamechar(20),AdminPasswordchar(20));

包含:

管理员编号AdminID、管理员姓名AdminName、管理员密码AdminPassword

Classinfo(Classchar(20)primarykey,

Majorchar(20),departmentchar(20));

班级号Class、专业Major、学院department

Courseinfo(CourseNumberchar(20)primarykey,CourseNamechar(20),Gradeint);

课程编号CourseNumber、课程姓名CourseName、学分Grade

StudentCourse(StudentIDchar(20),CourseNumberchar(20),Marksint);

学号StudentID、课程编号CourseNumber、得分Marks

Studentinfo(StudentIDchar(20)primarykey,StudentNamechar(20),Classchar(20),

StudentPasswordChar(20));

学号StudentID、学生姓名StudentName、班级号Class、学生密码StudentPassword

Teacherinfo(TeacherIDchar(20)primarykey,TeacherNamechar(20),

TeacherPasswordchar(20));

教师编号TeacherID、教师姓名TeacherName、教师密码TeacherPassword

Teachinginfo(CourseNumberchar(20)primarykey,TeacherIDchar(20));

课程编号CourseNumber、教师编号TeacherID

3.软件结构设计

3.1开发环境

基于windows7操作系统,数据库系统使用Mysql,服务器搭建使用Apache,Web编写使用PHP。

3.2系统功能结构

3.3系统结构-模块划分

3.3.1登陆模块

系统使用人员登陆系统,输入ID号密码,选择身份。

之后根据身份,查询系统数据库,判断该ID是否存在,密码是否正确,确认无误之后继续进行之后的功能。

实现程序段(login.php与login_check.php):

login.php

<

?

php

session_start();

$_SESSION['

firstlogin'

]=1;

>

head>

metahttp-equiv="

Content-Type"

content="

text/html;

charset=gbk"

/>

<

title>

学生管理信息系统<

/title>

style>

*{

padding:

0px;

margin:

}

a{color:

White}

body{

font-family:

Arial,Helvetica,sans-serif;

background:

url('

images/grass.jpg'

)no-repeatcenter;

font-size:

13px;

img{

border:

0;

.lg{width:

468px;

height:

100pxauto;

images/login_bg.png'

)no-repeat;

align:

center;

}

.lg_top{height:

200px;

width:

.lg_main{width:

400px;

180px;

025px;

align="

center"

;

.lg_m_1{

290px;

100px;

60px55px20px55px;

0pxauto;

.ur{

37px;

color:

#666;

236px;

4px28px;

images/user.png'

padding-left:

10px;

16pt;

.pw{

images/password.png'

.lg_foot{

80px;

330px;

6px68px068px;

align="

/style>

/head>

bodyclass="

b"

divclass="

lg"

lg_top"

/div>

lg_main"

lg_m_1"

formmethod="

post"

action="

login_check.php"

inputtype="

text"

name='

user_name'

class="

ur"

/>

password"

user_pass'

pw"

pstyle="

text-align:

center"

fontsize='

3'

face='

楷体'

strong>

请选择身份<

/strong>

/font>

:

br/>

/p>

bodystyle="

center;

"

selectname="

shenfen"

size="

1"

style="

optionvalue="

学生<

/option>

2"

教师<

3"

管理员<

/select>

inputname="

submit1"

type="

submit"

value="

登录"

/form>

login.php"

submitO"

重置"

/body>

/html>

Login_check.php

if($_SESSION['

]){

username'

]=$_POST['

];

password'

shenfen'

]=false;

$shenfen=$_SESSION['

$user_name=$_SESSION['

$user_pass=$_SESSION['

html>

登陆成功!

styletype="

text/css"

body{

background-image:

url(images/banner.jpg);

background-repeat:

repeat;

body>

$db=mysql_connect('

127.0.0.1:

3306'

'

root'

'

)ordie("

连接失败"

);

mysql_select_db('

management'

$db)ordie(mysql_error($db));

if($shenfen['

]==1)

{

$query="

SELECT

StudentID,StudentName,studentinfo.Class,Major,department

from

studentinfo,ClassInfo

where

StudentID='

$user_name'

ANDStudentPassword='

$user_pass'

ANDstudentinfo.Class=ClassInfo.Class;

mysql_query("

setnames'

gbk'

mysql_query("

SETCHARACTERSETgbk"

$result=mysql_query($query,$db)ordie("

ERROR"

if(mysql_numrows($result)==0){

echo"

用户名或密码错误!

.'

ahref='

login.php'

重新登录"

/a>

}

else{

>

palign='

right'

注销<

password_change.php'

修改密码<

."

course_select.php'

palign=right>

修改选课信息<

//showtheresults

echo'

tableborder="

0"

align=center>

td>

用户信息:

/td>

$row=array('

学号'

姓名'

班级'

专业'

学院'

echo'

tr>

foreach($rowas$value){

echo'

.$value.'

}

while($row=mysql_fetch_assoc($result)){

/tr>

}

/table>

//extract($row);

//echo$StudentID.'

-'

.$StudentName.'

.$class.'

.$StudentPassword.'

/br>

$query="

SELECT

studentcourse.CourseNumber,CourseName,Grade,Marks

from

studentcourse,CourseInfo

where

StudentID='

andstudentcourse.CourseNumber=CourseInfo.CourseNumber"

$result=mysql_query($query,$db)ordie("

未知错误!

选课信息:

课程编号'

课程名'

学分'

分数'

]==2)

//检查username是否存在

//检差password是否存在

//显示老师个人信息,获得任课科目

SELECTTeacherID,TeacherNamefromTeacherinfowhereTeacherID='

ANDTeacherPassword='

Theuserdoesn'

texistorpassword"

palign='

修改密码<

教师信息:

教师编号'

Teachinginfo.CourseNumber,CourseName

Teachinginfo,CourseInfo

TeacherID='

andTeachinginfo.CourseNumber=CourseInfo.CourseNumber"

Unexpectederror(mark)!

palign=center>

课程:

while(mysql_num_rows($result)!

=0&

&

$row=mysql_fetch_assoc($result)){

extract($row);

echo"

scole.php?

course=$CourseNumber'

echo"

$CourseName<

]==3)

//检查password是否正确

SELECTAdminID,AdminNamefromadministratorwhereAdminID='

ANDAdminPassword='

mysql_query("

tableb

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 经管营销 > 经济市场

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1