Campus website design
Published: 2004-03-17 Author:
table of Contents
Chapter 1: Popularization ...............................................................................................
1.1 Design Thought .................................................................................................... 1
1.2 Development Tools and Introduction ........................................................................
Chapter II: Website Overall Analysis and Design 2
2.1 Website System Analysis ............................................................................................ .2
2.2, Home Design 3
2.3, database design 4
Chapter 3: Detailed Design 4
3.1 Parents School Contact Book .................................................... 4
3.2 Online Library 11
3.3 Online evaluation voting system 20
3.4 Damage Examination Online Test System and Counter Production ......................... 22.
Part 4: Instructions for the system's instructions and installation 25
Part 5: References: 26
Appendix: Source File Code 27
Chapter 1
Today, the Internet has become an important channel for people to quickly acquire, release, and transfer information, which plays an important role in people politics, economics, and life. The publish information on the Internet is mainly implemented by the website. The information is also to be downloaded from the website from the website in the Internet "Ocean". Therefore, the status of website construction is obvious, it has become an important part of the government and enterprises informatization, which is subject to people's attention. In order to better run schools, improve school visibility, specialize in the website of Changsha City, Industrial and Commercial Technical College.
1. 1 design idea
Through the website, comprehensive publicity, display school style, strengths and characteristics, and release the major event arrangements and enrollment policies, enhance the contact between parents and schools, and implement partial schools on the Internet, improve the efficiency of the work.
1.2 Selection and introduction of development tools
Advantages of ASP:
Active Server Pages: "Dynamic Server Web", generally referred to as "ASP", the reason why ASP can be attached to and used, mainly due to the results generated are standard HTML format, and these programs are in the network During the server, use a general browser (such as IE or Netscape) to properly obtain the "execution" result of the ASP, and the result of this ASP is directly "browse" in the browser, unlike VBScript or JavaScript is Execute on the client (Client) browser, if you use the VBScript to design the program, the client (Client) can display the result of the program execution in the IE browser, but the client (Client) cannot be used. If you use the Netscape browser. Display the execution of VBScript.
ASP features:
Any development tool can develop ASP
As long as you use a general instrument editing program, such as Windows Notepad, you can edit. Of course, other web development tools, for example, FrontPage Express, FrontPage, etc., but it is recommended that you use the notepad to write, which saves money and convenient. If you use the web page editing that you want to write to write ASP, you may happen Some unexpected bizarre.
To eat all walks, because the ASP program is executed in the network server, the HTML file generated by the execution result is available for different browsers.
High language compatibility
The ASP is compatible with all ActiveX Script language, in addition to the HTML, VBScript, Java Script, Active X server components, and other manufacturers (Third) via "PLUG-IN" Party's language provided.
Higher security
If we directly view the original code of the webpage directly, we can only see the HTML file, the original ASP program code is not seen! This is the fact that the ASP program is executed first on the website service (the web server), converts the result into a standard HTML file, then transferred to the client (Client) browser, so the ASP program we have worked hard is not It will be easily seen to be stolen.
Easy to control database
ASP can easily connect a variety of different databases through the ODBC (Open Database Connectivity) driver, such as: Acss, FoxPro, DBASE, Oracle, etc. use.
Object-oriented learning is easy
The ASP has object-oriented (Object-Oriented) features, learning is easy, ASP provides five convenient powerful built-in objects: Request, Response, Sever, Application, and Session, if you use an APPLICATION object built by ASP Or the ASP program written by "Session" object can temporarily save the necessary information between multiple web pages.
Six internal objects of ASP
Object Name Function Description
RequestResponServerSessionApplicationObjectContext acquires information from the client to provide information to the client to provide some web server tools to user information in a session, which can only be accessed in an ASP-Application to make different client sharing information can be used Distributed transaction processing with Microsoft Transaction Server
So I chose ASP combined with FrontPage architecture Changsha City Business Vocational Secondary School Site
Chapter II Website Overall Analysis and Design
2.1 Website System Analysis
According to the previous design ideas, the website is decomposed according to the basic view of the system development, and the website can be divided from the content:
l The school style is shown through school summary, teacher style, campus star and some pictures.
l Advantages through news, vivid and lively educational teaching columns to show.
l Information Release through the bulletin board, information inquiry and other columns, the content has an enrollment policy.
Activity arrangement, etc.
l Some schools are based on the publication of the school and the number of participants, and the special selection of books
Rules, evaluation, examination, family school contact four major schools are implemented online.
2.2 Home Design
The website home page features a quiet, moving method, that is, the static main screen and dynamic picture combined, reflecting the vitality of the school, the static home page introduces the school style, the advantages, information release, for the four major schools, Establish a database query management system using ASP and database, using an interactive dynamic web screen to implement. Home structure diagram
Note: The expansion of the underline is a link mode
2.3 Database Design
The use of the database is Microsoft Access, which is intended to establish a Teach.mdb library file, which contains the following table files:
AllMessage Message Meter
LibBooks Book Information Table
Libcategories Book Category Meter
Libemps library user information table;
Stud Business Student Information Form
Chapter III Detailed Design
3.1 Parents School Contact Book
3.1.1 Features:
Using SQL syntax to filter specific parental message, let the teacher can make an independent answer for the opinions of a particular student's parents. At the same time, when you express your personal opinion, if you think the content of the opinion involves sensitive topics or opinions involved Private privacy, you can speaking in a "whisper" way, these "whispers" will not be displayed to let everyone see, of course, the teacher has the ability to manage, as long as you log in to the management mode, you can do separate students. Comment reply, and you can see the "whisper" left by the parents.
3.1.2 Composition Construction
A total of six parts:
1. Message Results Web guest.asp: It is used to show the parents' speech and the teacher's reply, and there are also two display methods for general mode and management mode.
2, parents' speech sheet website addMsg.asp: Let the parents fill in the content and select the nature.
3, parents' speech data processing ASP program add.asp: Handle the parental published advice, and record these comments data and turn web pages to the comments message result web page.
4. Teacher replies form page Teachans.asp: Let the teacher make an independent answer for the opinions issued by a particular student parent.
5, teacher reply data processing ASP program ANSSAVE.ASP: Hands the data content of the teacher reply, and simultaneously data and turn the web page to the comments message result page.
6. Data table file AllMessage: The Access Type Database file used to store parents to speak data with the teacher replying to the data.
"Data Table File" is responsible for the storage of parents' speech data with the teacher's reply content, which is the Access type library file, which is named: "Message.mdb".
The figure below shows the composition and flow chart of the home contact book:
Teacher reply
Parental message
Read in writing
Write
3.1.3 Database Structure Design
Database file "TEACH.MDB" section "AllMessage" column setting, as shown below:
Field name field type
3.1.4 Interface design and key points, difficult code design
Database & message display program page
Parents' speech and the teacher reply to the teacher reply to the database, to display the current parent's speech and the teacher's reply data in the web page, you must first make a database link and open, to link the database We must use the ADO object group for the CONNECTION object; To open the database, you must use the RecordSet object of the ADO object group, the program:
SET CN = Server.createObject ("AdoDb.Connection")
CN.Open "FileDSN = C: / Program Files / Common Files / ODBC / DATA SOURCES / MS Access Database.dsn" SET RS = Server.createObject ("AdoDb.Recordset")
SQL = "SELECT * from allMessage Order By Message DESC"
RS.Open SQL, CN, 1, 1
The Recordset object is responsible for browsing the data taken from the database, and the Connection object is only responsible for linking the database and does not use the data in the database, so a Recordset object that can access database data can be established.
Access "TEACH.MDB" database using the RS.Open method
RS.Open SQL, CN, 1, 1
Use the Open method to open the data table or perform the SELECT command parameter setting as follows:
1, parameter one (source): For the data table or SQL instruction to be opened.
2, parameter 2 (ActionConnection): Specify an open database object, set this parameter to link We have established a good Connection object "CN".
3, the parameter three (CURSORTYPE): Specifies the open type of the Recordset, 1 is readable and free to move.
4, parameter four (LockType): Specify the lock type, 1 is read-only.
Data Sort by SQL Directive
1. Filter statement of SELECT instruction:
Format: SELECT ...
In the SQL language: "SELECT" Datasheet "is selected in some" field "data.
2. If the data table data to be selected contains more than one field, we can use the "," comma, the name is separated.
3. If the data table data to be selected contains all the fields, you can use the multimeted character "*" to represent all of the fields.
SELECT instructions for sorting data
1. When we want to be selected, the data recorded data can be sorted according to the content of a certain field, as long as these sorting bars are placed after the "Order By" reserved word, then this is sorted The statement is connected behind "SELECT ... FROM".
2. The default sort method of "ORDER BY" is "from the small row to the big", but if you want the sort mode, "from the big row to small", then we can add "DESC" reserved after the column name! The sort mode is changed to "from the large row to small".
Open the statement in the Open Database ASP program in the "Show Message" webpage:
Select * from allmessage Order by message dates DESC
The function is: Take data from all fields from the data table "AllMessage", and sort the removed data record content in accordance with the "Big Row to Small" sorting by the "Meet Date" field.
Message Displaying the management mode of the web page
The "Show Message Opinions" must have the function of display mode selection. When the display mode is in general, the general statement of the parents can be displayed, and they have to hide the "whisper". When the teacher logs in to the management mode with a password, the general speech must be displayed all of the data to whisper, and it has to make the teachers to make an independent answer for the opinions issued by the parents of a particular student.
These two cases are implemented by password login management mode: