HTML & CSS Example Exercise Files
- Convert an XHTML 4 into an HTML5 file.
- Download the zip file
- Open up sample01.html
- Make appropriate changes:
- Convert the DTD to HTML5.
- Minify the meta tag
- Remove excess noise from the link tag
- Convert the DTD to HTML5.
- Convert everything not nested in <li>'s into HTML5 elments, removing classes and ID's that are no longer necessary
- Compare to sample02.html, which is a possible solution
- Select This! Add CSS3 Selectors to style03.css to ensure that the CSS properties and values are applied to the right elements.
- Download the zip file
- Open up style03.css
- Make appropriate changes:
- Use a pseudo class to target the HTML element
- Add a media query to target the <body> when the page is viewed on large screens
- Use combinators to match elements only if they are direct children of other elemeents
- Use selectors to target the <li>s in the nav based on order
- Use a combinator to match the <li> than is next to the active nav <li>
- After editing style03.css to target elements based on relationships rather than on CSS, compare to style04.css, which is a possible solution
- Add whistles and bells to style05.css, making it look like a native mobile application.
- Download the zip file
- Open up sample05.html
- Make appropriate changes:
- Create a gradient for the whole div
- make the header appear beveled with inset shadows, and make its text pop
- Add styling to the <aside> byt making the corners round, adding a shadow and creating a background effect
- Make the text appear a little bolder, but not a bold as font-weight: bold by giving a slight shadow in the current color.
- Give the nav some styling with gradients and borders
- give the active link a 1) gradient, 2) rounded corners of 5px, 3) a pop
- After editing File 5 to include box shadows, text shadows, rounded corners and gradients, compare to File 6, which is a possible solution
Zip file