Professional Web Design: Techniques and Templates- P9
Thông tin tài liệu:
Nội dung trích xuất từ tài liệu:
Professional Web Design: Techniques and Templates- P9 382 Chapter 14 ■ Case Study: A CSS Form Adding the Comments Row The code required to produce the Comments row is almost identical to several of the other rows, barring one difference—the row includes the tag, which does not force the height of the row for compliant browsers, such as Firefox. The designer, therefore, needs to force the height of the row. One way to do so is to add a local style to the parent , shown in Listing 14.9. Without declaring the height of the row, the row would look like the right side of Figure 14.9. The left side illustrates what the row looks like if a height is defined. Listing 14.9 XHTML and CSS Code for Comments Row Comments: Figure 14.9 The Comments row and how it will appear in compliant browsers when a height is and isnt defined when using the tag.Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. Game Developing GWX Building the Form Row by Row 383 Adding the Options to Select Rows The Options to Select rows add two more situations a designer may or may not come across. The first is to include only a section title and nothing more in a row. This is accomplished by merely not including a form field. The second is a little more involved. It requires two things: (1) define appropriate margins for posi- tioning in the parent , which, in this case, sets the bottom margin to 20 pixels and the left margin to 80 pixels; and (2) use a table to lay out the form fields in columns and rows. While the latter could be accomplished with CSS, the more simple and straightforward route is to use a table. The code in Listing 14.10 shows how simple the table needs to be. Listing 14.10 XHTML and CSS Code for Options to Select Row Options To Select: Sample Text Option 1 Sample Text Option 2 Sample Text Option 3 Sample Text Option 4 Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. Game Developing GWX 384 Chapter 14 ■ Case Study: A CSS Form Sample Text Option 5 Sample Text Option 6 Adding the Submit and Cancel Buttons The final row contains the Submit and Cancel buttons. There are several things to note about this section of code: (1) a local style is added to the to provide 20 pixels of padding on the top and bottom, (2) the tag has added so that all browsers recognize the tag and account for its width, and (3) the two but- tons are placed side by side without any additional styling. The Cancel button calls an image, while the Submit button is generated with XHTML (see Listing 14.11). Listing 14.11 XHTML and CSS Code for Submit and Cancel Buttons The Final Product When all the code and images are added, the final 13-row form only needs the back-end functionality added to it. Figure 14.10 is the visual representation of the final code, which is shown in Listing 14.12.Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. Game Developing GWX Building the Form Row by Row 385 Figure 14.10 How the final form appears prior to being added to the design (see Figure 14.1). Listing 14.12 XHTML and CSS Code for Completed Form html, body { margin:0px; padding:10px; font: 9.8pt arial, helvetica, sans-serif; color:#000000; } .a5-form { margin:0px 0px 0px 0px; } .a5-required-field {Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. Game Developing GWX 386 Chapter 14 ■ Case Study: A CSS Form color:#D60000; } .a5-disabled-field { background:#7ED0D4; } .a5-disabled-checkbox { background:#7ED0D4; voice-family:\}\; voice-family:inherit; } html>body .a5-disabled-checkbox { padding-top:3px; } .a5-row-1 { height:30px; } .a5-row-1 label { float: left; width: 220px; text-align: right; padd ...
Tìm kiếm theo từ khóa liên quan:
thiết kế web giáo trình photoshop thiết kế layout CSS cơ bản giáo trình flashGợi ý tài liệu liên quan:
-
Báo cáo thực tập: Đề tài thiết kế Web
77 trang 568 2 0 -
Đề thi thực hành môn Thiết kế Web - Trường Cao đẳng nghề Vĩnh Phúc
3 trang 268 2 0 -
182 trang 175 0 0
-
MỘT SỐ ĐIỂM CẦN CHÚ Ý KHI THIẾT KẾ WEB
5 trang 113 0 0 -
GIÁO TRÌNH LẬP TRÌNH WEB_PHẦN 2_BÀI 3
3 trang 103 0 0 -
Giáo trình Nhập môn thiết kế website
58 trang 83 0 0 -
Thiết kế dàn trang nâng cao trong khám phá Adobe Indesign
340 trang 76 1 0 -
Tài liệu giảng dạy Thiết kế giao diện Web - Trường CĐ Kinh tế - Kỹ thuật Vinatex TP. HCM
88 trang 72 0 0 -
81 trang 68 0 0
-
112 trang 64 0 0
-
Hướng dân sử dụng Navicat để Create , Backup , Restore Database
7 trang 63 0 0 -
Giáo trình môn Kỹ thuật vi điều khiển: Thiết kế web và vi điều khiển - Chương 2
39 trang 59 0 0 -
Giáo trình Photoshop (Nghề: Lập trình máy tính-CĐ) - CĐ Cơ Giới Ninh Bình
231 trang 53 1 0 -
Giáo trình photoshop - Chương 3: Cơ bản về chỉnh sửa ảnhPhotoshop CS
19 trang 48 0 0 -
0 trang 46 0 0
-
GIÁO TRÌNH THIẾT KẾ WEB: TỰ HỌC MACROMEDIA FLASH 5.0
18 trang 40 0 0 -
Giáo trình hướng dẫn tạo ảnh cưới nghệ thuật bằng phương pháp blend màu và tạo quick mask p1
7 trang 40 0 0 -
Bài giảng Thiết kế và lập trình Web - Bài 5: PHP cơ bản
137 trang 39 0 0 -
giáo trình html và thiết kế web: phần 2 - Đh công nghệ
119 trang 39 0 0 -
111 trang 39 1 0