tailieunhanh - Facebook API Developers Guide PHẦN 8

Trước khi bạn nhận được quá xa vào thiết kế giao diện người dùng, chúng ta hãy lấy một bước trở lại và làm một chút kế hoạch để kết thúc trở lại cơ sở dữ liệu của bạn. Oracle, Derby, hoặc Microsoft SQL Server, sẽ không được nhiều sự khác biệt bởi vì bạn sẽ không được nhận vào bất kỳ các tính năng tiên tiến của động cơ RDBMS. | Building a Facebook Application Start to Finish 93 - Profile edit Friends Networks Inbox home account privacy logout facebook C-J-J Congratulations Your first application is up and running. I L------------------------------------------------------------------------------ Figure 4-17. FBML success Before you get too far into the UI design let s take a step back and do a little planning for your database back end. Creating the Database When developing a web application one of the more complex tasks is developing a database back end. For the purposes of this example I ll be using MySQL since it s quite typical for developers to have this as their back end. If you re using another RDBMS such as PostgreSQL Oracle Derby or Microsoft SQL Server there won t be much of a difference because you won t be getting into any of the more advanced features of the RDBMS engine. Designing the Database Now that you have things set up let s think about the design of your database. Like I mentioned at the beginning of the chapter this is a game review system. It will show off how to do a bunch of techniques in Facebook to give you a good idea of how to use these features in your own application. To begin your design you ll need a table that holds review data. This table will hold a user ID UID the game being reviewed a rating and a generated primary key for convenience. You also need a game table to link to the review table that includes a game title publisher ESRB rating game genre and release year. If you were developing this from scratch you would use another table to record usernames e-mail addresses passwords with some type of obfuscation in place and other information such as names addresses and so on. Since Facebook takes care of all of this the only information you really need from the user is the uid token in fields that will need any type of personal information for users. Just to reiterate it s a good idea to keep as little personal information about your users as needed and

TÀI LIỆU MỚI ĐĂNG
15    130    0    12-06-2024
crossorigin="anonymous">
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.