practical liferay Java -based Portal Applications development apress phần 9

Thêm một thư mục con Trước tiên, bạn sẽ thêm các thư mục con trong thư mục cơ bản. Thực hiện theo các bước sau để làm như vậy: 1. Nhấp vào liên kết cơ bản trong danh sách thư mục hiển thị trên màn hình ứng dụng chính. 2. Nhấp vào nút Add thư mục con trên màn hình hiển thị. | 270 CHAPTER 10 PUBLISHING DYNAMIC CONTENT This screen displays a list of existing templates at the bottom. This list is currently blank because you haven t yet defined any templates. We ll remedy that now. Adding a Template To create a new template follow the steps listed here 1. Click the Add Template button. You will see the screen shown in Figure 10-12. Figure 10-12. Creating a new template 2. Do the following things on the displayed screen a. Autogenerate ID Mark this check box. The application will now autogenerate the ID for the new template. b. Name Enter Announcement Template. c. Description Enter This is a page template for the announcement type of journal article. CHAPTER 10 PUBLISHING DYNAMIC CONTENT 271 d. Cacheable Leave this box checked the default . e. Structure Click the appropriate button to select or remove the earlier selected structures. f. Language Type You get three choices here i. VM Velocity is a powerful Java-based template engine. It renders data from plain Java objects to various formats. ii. XSL Extensible Stylesheet Language XSL is a language for expressing style sheets. Like CSS it contains information on how to render an XML document. iii. CSS Cascading Style Sheets CSS is a widely accepted standard for creating style sheets to define how web-page information will be rendered. g. Script Specify the file that defines the template structure. Because you can create the template structure in VM XSL or CSS you should select the appropriate file based on the language selection in the Language Type field. To locate the file on the system use the Browse button. Alternatively you can create a new file on the fly using the Launch Editor button. Note As mentioned earlier a template defines the formatting instructions for each field defined in the structure. When the user views the article these formatting instructions will be applied to the various fields defined in the structure and the formatted output will be rendered in the user s browser. .

Không thể tạo bản xem trước, hãy bấm tải xuống
TỪ KHÓA LIÊN QUAN
TÀI LIỆU MỚI ĐĂNG
2    121    2    27-06-2024
Đã 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.