Changing style with CSS according to markup position

You can use the + symbol in css to alter the way markup is styled according to it's position in the document. This page demonstrates how the boldness of text can be increased the lower in the document the text appears. View the source code.

See 5.7 Adjacent sibling selectors of the Cascading Style Sheets, level 2 CSS2 Specification for full details.

Last modified: 05/05/2006 (most likely earlier as a site migration in 2006 reset some dates) Tags: (none)

This website is a personal resource. Nothing here is guaranteed correct or complete, so use at your own risk and try not to delete the Internet. -Stephan

Site Info

Privacy policy

Go to top