PHP Conference Booking System

Source: Internet
Author: User
Tags php language


Recently this time, in PHP to make a room reservation system, due to the beginning of the PHP language, so not very familiar with the grammar, in this study and production process, found some problems, by the time of the weekend, summed up, hope to be like me this rookie, helpful, If you find a bug or a controversial place, please note that communication, interaction and Exchange, thank you.


I am using the YAF framework, Ngnix server, MySQL database, php5.5. For the installation of the system, please refer to the previous post, the address is as follows: http://mig1924615.blog.51cto.com/9385857/1755532


Just beginning to feel that, with PHP to do a web version of the conference booking system, not so complicated, do a few buttons, do a table, and then to the front-end to consult, with a good view of the style is OK, but do it will find that above his business.


A simple sketch was drawn, as follows:

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/7F/D4/wKioL1cvRM7AgqeDAAEQt5WCQkw336.png "title=" Huiyi.png "width=" 1076 "height=" 424 "border=" 0 "hspace=" 0 "vspace=" 0 "style=" width:1076px;height:424px; "alt=" Wkiol1cvrm7agqedaaeqt5wcqkw336.png "/>


First, the Meeting reservation section, the added information not only to add to the database, but also to add the success of the same day to display the meeting booking information, and all you have to do is to consider how to map this information to the display panel on the right.


Next, on the left side of the calendar, click on the table on the right to display the scheduled meeting information for the corresponding date, and to implement the meeting cross-line processing.


Then, the button at the bottom left, cancel the meeting relatively simple, add the meeting, in the model logic part, need to handle, add some judgment, logic clear words, should not be the problem, then the key is to modify the meeting, the corresponding processing, as well as the data update, the page display and so on, need to be handled well.


The key part of the technology involved is that there are more jquery and Ajax parts, and the PHP-related parts may be easier to get started with, but there are a lot of things to be aware of in the top two.


Here is a detailed explanation:

    1. The right side of the table, not written dead, all data display, including time period, booking information, conference room name, etc., are dynamically generated, through the database real-time reading information, dynamic display, add success, will display the corresponding information, if the output of such a style, did think for some time, If the logic is straightened out, it will be much quicker. So, remember, do not rush programming, to clear the logic, and then to write code, so that, even if there is no bug, you will be clear logic, to make the next change, otherwise, will be the code of their own miserable.

    2. Second, by default, the table shows that the default day of the meeting information, click on the Calendar section, you can display the corresponding date button, this part, need to know, you use the JS calendar plugin, here, to you recommend two, particularly practical, and features are very powerful, Datetimepiker can also meet the needs of time selection.

JS plugin link as follows: Link: http://pan.baidu.com/s/1o7Qb52q Password: Maci


3. Note that the right side of the table, data information is generated through the Foreach Loop array, then, you will find that it is generated horizontally, then for the meeting of the booking information display, as well as cross-line processing, to carry out serious thinking, handle the logical relationship here, especially prompted, otherwise, The resulting table will be hard to see and will not be the expected effect of this drawing.


4. With regard to the problem of data transmission, generally think of the JSON way of Ajax, using post to drive it to the controller layer, this is not wrong, such as the conference room booking information is so processed, and then in the logic layer to judge, whether the meeting room conflict, the information is complete and so on , and then make the appropriate response and feedback information. Use the display method to display its information to the index interface.

--------------but!!! -----------

What if this is the case? I choose the appropriate date, I need to upload it to the controller layer, and then according to the date, query out the meeting booking information, and then let it display to the index interface, this time, you can also use Ajax to pass parameters???

If you say yes, then you must not have tried it, you might as well do an experiment.

I can tell you clearly, cannot, because, you will always get, response time-out of the bullet box display ...

Ajax can't be used with display at the same time, so how do I pass this parameter over?

--------------rely on it!!! -----------

Header ("Loacation: url with parameters");

Then, in the controller to obtain the corresponding parameters, different frame URL definition form is not the same, the parameter format is not the same, you can query the corresponding data, so that the parameters can let index use, the function of the calendar part is perfect.


5. Modify the meeting information, is the binding of the Click Function, you can click in the Yellow section, and then can be modified, it is necessary to note that the need to be based on the conference ID parameter binding, and then display to a modal box, when the Modal box pops up, the display will be, modify the meeting information, and then go through the process of adding But you cannot use the same modal box, because you need to walk a process alone, the same principle, the same judgment.


6. Here, there is a logical comparison of the key is: the judgment of the time period, if you determine the start time and the end of the inclusion of the problem, where the meeting is scheduled to conflict, just find out whether it is included, then, the meeting display part, because each time only judge a row, so to repeat the judgment, including the problem, especially the Need to think clearly.


7. The next step is to further improve the conference display function, optimize the interface, and then, the landing function, divided into different permissions, level division and so on.


The above is the recent project some simple summary, may write not too detailed, if which part is not too clear, can leave a message, then give you detailed answer. Because of the nature of the company involved in the system, so do not post code, please understand.







This article is from the "zebra does not love grassland" blog, please be sure to keep this source http://mig1924615.blog.51cto.com/9385857/1771295

PHP Conference Booking System

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.