1、bbs论坛系统的设计与实现论文答辩资料(BBS forum system design and implementation of the thesis defense information)In order to facilitate the exchange of information, in conjunction with dynamic service web pages (JSP) and SQL2005 technology, developed this user-friendly small forum system. The forum uses dynamic ser
2、vice page (JSP) technology construction forums backbone frame, making use of SQL2005 system database, using some knowledge of Struts, Spring and Hibernate three framework technology, combined with the use of AJAX technology, through the implementation of the forum system the function of a relatively
3、 complete.The forum provides a communication platform for users, registered users here can freely express their views and opinions on the theme of the forum posts, also can timely solve the issues raised by users, to obtain useful knowledge. This system uses JSP and SQL Server technology as the webs
4、ite erection, selects the SQL2005 database and the Windows XP operating system. This forum also has some special functions, powerful search function and so on.System technology and operating environmentIntroduction to JSP TechnologyJSP is a server-side scripting language. It is a dynamic web page ge
5、neration technology based on SERVLET. Its bottom implementation is JAVA SERVLET. JSP (JAVA, SERVER, PAGES) consists of HTML code and JAVA code embedded in it, 6. The server is client requests after the code in the pages, and then the characteristics of production of HTML page is returned to the clie
6、nt browser JSP is object-oriented, cross platform, and SERVLET as stable, you can use the SERVLET provided by API, and overcomes the shortcoming of SERVLET. When using JSP, 7 and JAVABEANS are commonly used in combination to separate the interface performance from the business logic.Introduction to
7、JAVABEAN TechnologyJAVABEAN is a JAVA based organization model, somewhat similar to MICROSOFTs COM formation.In the JAVA platform, you can extend the functionality of the JAVA program indefinitely, and you can quickly produce new applications through the combination of JAVABEAN. For programmers, the
8、 best thing about JAVABEAN is that you can reuse code and make it easy to maintain and so on. JAVABEAN runs through the JAVA virtual machine (JAVA VIRTUAL MACHINE), running JAVABEAN, and the minimum requirement is JDK1.1 or more. The traditional application of JAVABEAN lies in the field of visualiza
9、tion, such as the application under AWT. Since the birth of JSP, JAVABEAN has been applied more and more in the field of non visualization, and has shown a growing vitality in server-side applications, 8.Other techniquesThe system also uses some other technologies, such as Struts9, Hibernate10, Spri
10、ng11, AJAX, etc These will be introduced at the back of the code.Running environmentIn order to ensure the efficiency and reliability of BBS forum management system, the server should have higher software and hardware configuration, and the clients request is not very high. This application can be w
11、idely used on the Internet, Internet, and also for internal lans. Its operating requirements are as follows:System requirements analysis specificationSystem introductionThis system is based on the B/S structure of a small forum, mainly based on the Windows platform, through this forum, users can ach
12、ieve interactive communication.functional requirementThrough the understanding of some well-known forums on the Internet, the forum should at least realize the following functions:(1) registration management: to the user name, password simple verification, can prevent the use of page refresh repeate
13、d registration, the existing user name can not be repeated registration.(2): you can browse posts for keyword search posts or content according to the author, the forum section display card, display card details, visit the post does not require users to log in, but the user must login before the rep
14、ly card.(3) publish and reply the post: only login user can publish and reply the post, and have limited to the word of the post.(4) user personal information management: landing users can edit personal data after registration, such as modifying passwords, etc.,However, the user name cannot be modif
15、ied. You can also post your own posts: modify, delete, etc(5) reply Management: the moderator of each forum can manage the post of the post which is managed by the forum, which can shield the reply.(6) forum management: only administrators have the authority, administrators can add, delete the forum
16、, you can also modify the forum information, such as the name of the forum, the higher level section, moderator.(7) user management: only administrators have this permission, administrators can disable, enable users, user password reset.(8) announcement management: only administrators have the autho
17、rity, administrators can add, delete announcements.(9) post management: each forum section of the moderator can manage their own section of the post management, you can shield and delete posts.overall designThis system adopts B/S mode design, which is convenient for system maintenance and use. MVC d
18、esign patterns and multi-layer architecture based on J2EE platform design 13, so that the system has good scalability, in order to meet the current use of demand, but also take into account the possible expansion of the system after the function. The system is divided into several relatively indepen
19、dent modules, but these modules are centrally managed.General structure and module designThe system can be divided into two parts, the front desk and the back stage. The front desk is provided for the general users and the moderators, and the backstage is for the administrators to do some system mai
20、ntenance. Treatment processFor the users of this system, they can be divided into the following categories: unregistered users, registered users. Registered users can be divided into three categories: general users, moderators and administrators. Depending on the users role, the user has different p
21、ermissions. Analyze the business process of this system according to this.Database designBefore the construction of the website system, structure design and specific classification of general must be used in system data, it is necessary to achieve clarity, but also can adapt to the system function c
22、all, and not have the structure of logical confusion, to ensure that the key data will not be damaged in case of an accident, can be said that the database is heavy priority system.Database design should follow some rules, a good database to meet some strict constraints and requirements. Try to sepa
23、rate the tables corresponding to each entity, an entity corresponding to a table, to analyze what attributes the entity has, what fields it corresponds to, and the links between entities. Entity, attribute and relation are three elements that should be considered in conceptual design, and also the c
24、ore of a good database design 14.System detailed designThe technology used in the front and back page design is JSP. The reason for choosing it is that JSP technology has the following features:1) Write, Once, Run, AnywhereJSP technology inherits the advanced concept of JAVA congenital, “Write Once
25、Run Anywhere“, this concept is more and more far-reaching impact on the Internet industry interactive, WEB design concept. JSP Pages can be very easy to open platforms across WEB server software to design and open source code.2) supports a variety of dynamic web formatsAt present, there is no defini
26、te standard for what format the web pages should be designed for using JSP technology. General JSP technology that can support the traditional HTML/DHTML browser file format, and can support applications with wireless communication devices such as mobile phones, PDA and other equipment for the web b
27、rowser VML file format, can also support other B2B application XML format. Compared with other WEB applications in the past, JSP technology has its distinct characteristics.3) JSP tag scalabilityAlthough JSP and ASP are using the tag and script technology to create dynamic WEB pages, but JSP technol
28、ogy enables developers to extend the application of JSP tags, JSP developers can custom tag libraries so web designers can make full use of compatible with XML tag technology, greatly reducing the dependence of script language.Because of the specified tag library technology, web producers have reduc
29、ed the complexity of making web pages and multiple web extensions that are critical to 15.4) reusability of JSP across platformsJSP developers have been concerned about reusability during the development process, and JSP shows that enterprise JavaBean or tags are cross platform and reusable. The ent
30、erprise JavaBean can access the traditional database and distributed system model and has been working in UNIX and WINDOWS platform, the JSP label can be extended to provide a convenient function compatible with the XML interface for developers, namely sharing the packaging function “complete indust
31、rial standardization. This set based model can effectively improve the efficiency of application development. Because this model enables developers to quickly create template applications using quick child builds. Then complete and add some additional functionality to package it into a JAVABEAN buil
32、d.5) ease of maintenanceThe application based on JSP technology application based on ASP more easy maintenance and management. Scripting languages are good for small applications, but not for large, complex applications, because JAVA is structured and easier to create and maintain large, built up ap
33、plications.In this page, if users click “Browse“ into the hyperlink, which is equivalent to the identity of visitors to enter the forum, the forum is to enter the home page (Figure 5.2), then just have permission to browse and search posts. If the user enters the correct user name and password, it w
34、ill enter the home page of the forum as a user. The user can have more permissions to browse and search the post, modify personal data, delete and modify the subject Posts published, and publish and reply to the post. If the user enters incorrect information, the system blocks access to the home pag
35、e of the forum or jumps to the login page. If the user clicks on the “registration“ hyperlink, it enters the registration pageForumIn this page, a lot of information is displayed. Mainly for each section of the detailed information, including the name of the section, moderator, published in the foru
36、m under the subject of the total number of posts, as well as the latest post of information. If you have a post, show the topic, author, and time of the post, and provide a hyperlink to the topic of the post. Click on it to enter the detailed information page of the post. If there is no published po
37、st, it shows no longer. The page also displays information about announcements, that is, what is displayed on the bulletin board. On the page also provides the function of search posts, you can accurately search according to the authors name and fuzzy search according to the content of the post. If
38、the user enters the page after logging in, the page will provide a hyperlink to the “personal center“ and click on the link to enter the personal information center page (as shown in Figure 5.6). If the user is browsing through the page, the hyperlink is not provided.Registration pageUsers can enter
39、 registration information on this page, including user name, password, character signature and avatar.The user name, password and signature are required, the first picture is the default option, the user can choose again. In the user before submission are verified to fill in the information, includi
40、ng the user name is not empty and can not be repeated, the password is not empty, the password length must be greater than or equal to 4, two input password must be consistent, character signature is non empty, and the length is less than 50. In the unique validation of the user name, the AJAX techn
41、ique is used to check if the user name exists in the database when the user enters the user name and the text box loses focus,If it doesnt exist, then display “Ok“ in the blue font after the text box, and you can use this name “,“ if it exists, then display “No“ in red font after the text box. This
42、name is occupied!“. When the submission is successful, jump to the login page.Heres a brief introduction to AJAX technology. AJAX is called “Asynchronous JavaScript and XML“ (asynchronous JavaScript and XML),Web development technology that creates interactive web applications. It enables browsers to
43、 provide users with a more natural browsing experience. Before Ajax, the Web site forces the user to enter the submit / wait / re display paradigm, and the users actions are always synchronized with the servers “think time“. Ajax provides the ability to communicate asynchronously with the server, th
44、ereby freeing the user from the loop of request / response. With the help of Ajax, you can update the UI immediately using the JavaScript and DHTML when the user clicks the button and issue an asynchronous request to the server to execute the update or query the database. When the request is returne
45、d, you can use JavaScript and CSS to update the UI accordingly, instead of refreshing the entire page. Most importantly, the user doesnt even know that the browser is communicating with the server: the Web site appears to be instant response.Publish pageThe user can fill in the information of the po
46、st, including title and content. It was also verified before submission: title is not empty and length is less than 50. Post content is not empty and length is less than 2000. In order to prompt the user to control the input, the number of characters that are dynamically displayed by the user is rea
47、lized by JavaScript. To avoid repeated submissions, verification code is provided that is submitted only when the correct validation code is entered.In this page, details of the post and details of the post are displayed. And to achieve paging function, each page shows 5 replies. Only the login user
48、 displays the “reply post“ and “issue topic“ two buttons, and replies to the form of the post show. For users who do not log in, they are not displayed. If the login users identity is the moderator, and the post is located under the user management forum section, will be in the subject post after th
49、e “shield this post“ and “delete“ two hyperlinks. Respectively realize shielding posts and delete the function of the post. In addition, in response to the post, to provide “shielding this reply“ hyperlinks to achieve the reply of the post of shielding operations.Personal center pageIn this page, information about the users personal data and posts is displayed. When the user clicks on the hyperlink to edit the profile, he enters the page where the profile is edited and changes to the personal information. In addition, pagination on the page shows the theme Post is