Đang chuẩn bị liên kết để tải về tài liệu:
Agile Web Application Development with Yii 1.1 and PHP5 phần 2
Đang chuẩn bị nút TẢI XUỐNG, xin hãy chờ
Tải xuống
Nếu bạn đã điều hướng vào thư mục ứng dụng web của bạn, bạn cũng có thể envoke công cụ dòng lệnh yiic bằng cách tham chiếu các đường dẫn tương đối được bảo vệ / yiic chứ không phải là đường dẫn đầy đủ mà Yii được cài đặt. Vì vậy, các cách tương đương để bắt đầu trình bao từ trong thư mục sẽ được:% được bảo vệ / yiic shell | Chapter 2 cd Webroot demo Then execute yiic with the following shell command YiiRoot framework yiic shell Yii Interactive Tool v1.1 Please type help for help. Type exit to quit. If you have navigated into your web application folder you can also envoke the yiic command-line tool by referencing the relative path protected yiic rather than the fully qualified path to where Yii is installed. So the equivalent way to start the shell from within the folder would be protected yiic shell You are now at the prompt within the interactive shell. You can type help to see a list of commands available to you within this shell help At the prompt you may enter a PHP statement or one of the following commands - controller crud form help model - module Type help command-name for details about a command. We see there are several command options available. The controller command looks like the one we want as we want to create a controller for our application. We can find out more about this command by typing help controller from the shell prompt. Go ahead and type that in. It provides usage a general description parameter descriptions and some examples. help controller USAGE controller controller-ID action-ID . DESCRIPTION This command generates a controller and views associated with the specified actions. 23 Getting Started PARAMETERS controller-ID required controller ID e.g. post . If the controller should be located under a subdirectory please specify the controller ID as path to ControllerID e.g. admin user . If the controller belongs to a module please specify the controller ID as ModuleID ControllerID or ModuleID path to Controller assuming the controller is under a subdirectory of that module . action-ID optional action ID. You may supply one or several action IDs. A default index action will always be generated. EXAMPLES Generates the post controller controller post Generates the post controller with additional actions contact and about controller post contact about Generates