However, the Stylib ?¬? le multi_level_menu_class.css is the
drop-down menu ?¬? le I recommend, as that code has been through
more use on real sites, supports more levels, and with the addition
of a second class to the container, can stack the top level of the
menu vertically for use in a navigation sidebar. While the code for
these menus is fairly complex, once it??™s written (which, in your case,
it is), it??™s fairly easy to implement drop-down menus in a dynamic
site. The back-end system only needs to write out the XHTML list
structure, and as is typical when using JavaScript, not custom code
for each element of the menu.
And that brings us to the end of this long chapter. I hope these
examples inspire you to create your own versions of elements like
these for yourself, or at least to take and modify the ones that I have
shown here. In the ?¬? nal chapter, we will use our new CSS skills to
assemble the layouts and components we have seen so far into ?¬? nished
Web pages.
makes each li the width of the ul
and therefore stack
adds borders around the dropdown
overrides the removal of top level
left border
a border across the top of the
drop-down
a hack for IE6??”doesn??™t understand
:?¬? rst-child
adds a top border to the dropdowns
in IE6
CHAP T E R 7
Building Web Pages
231 STYLIN??™ WITH CSS
IN THIS FINAL CHAPTER, we??™ll bring together everything
you have learned in the preceding chapters and look at how
to organize pages into a complete site.
Pages:
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269