June 2025
Beginner
817 pages
31h 30m
English
Basically, you already know the CSS features you can use to customize images and graphics with CSS if you’ve read the book from the beginning. You can also set the size of the images using the CSS features, width and height. For example:
....large { width: 325px; height: 267px;}.medium { width: 225px; height: 184px;}.small { width: 125px; height: 103px;} }
Listing 14.27 /examples/chapter014/14_4_1/css/style.css
For example, with these three classes, you can conveniently output the same image in three different sizes. Instead of width and height, you just need to specify the corresponding class name for the img elements. You can see the result of the following HTML lines in ...
Read now
Unlock full access