HTML and CSS Reference
In-Depth Information
Figure 8-26. Scaling the box up does not break the rounded-corner effect.
The addition of a seemingly superfluous div to finish the technique is not ideal, but with
a bit of planning you may not need to do this—in our example, it would be possible to apply
a class to the last list item and add the background image there.
Conclusion
JavaScript is a powerful tool in the right hands but is not always required for visual effects on
a web page, and HTML need not be overtly complex to achieve certain stylish touches. The
aim of this chapter was to show that most, if not all, of what you may have used in the past—
for example, JavaScript—to create common page elements can be done with CSS. Even better,
though, you can usually do it more simply, with more semantic and meaningful markup and
in ways that offer you great flexibility for change later on. And for those common features
on a page that have not been covered here, we hope the examples we provided can give you
enough hints about how to tackle the problem for yourself.
So with that out of the way, we'll borrow some techniques from print design, and turn to
typography in our next chapter. We'll explore how some simple typographic techniques can
really improve the look of our web page text.
Search WWH ::




Custom Search