Get started (or continue) with Web languages. This assignment will introduce (or reintroduce) you to HyperText Markup Language (HTML), Cascading Style Sheets (CSS), and Scalable Vector Graphics (SVG).
There are three parts for this assignment. You may complete the assignment in a single HTML file or use multiple files (e.g. one for CSS and one for HTML). You may not use D3 or any other external libraries for any of this assignment. The Mozilla Developer Network documentation serves as a great reference for the technologies involved in this assignment. In addition, Scott Murray’s Interactive Data Visualization for the Web is a useful reference (see Chapter 3).
The assignment is due at 11:59pm on Friday, September 6.
You should submit any files required for this assignment on Blackboard. You may complete the assignment in a single HTML file or use multiple files (e.g. one for HTML and one for CSS). Note that the files should be linked to the main HTML document accordingly in a relative manner. If you submit multiple files, you may need to zip them in order for Blackboard to accept the submission. The filename of the main HTML document should be a1.html
.
Create an HTML web page with the title “Assignment 1”. It should contain the following items:
Use the following html to structure this information:
<div id="info">
<div class="left">
<!-- Your Name & Id -->
</div>
<div class="right">
<!-- Class Title & Assignment -->
</div>
</div>
All of the lines you add should be heading elements. The first line (your name) should be larger than the others. Do not add anything except the header tags (with id
and class
attributes only) and the text in HTML. Two lines should be added the <!-- Your Info -->
section and two lines to the <!-- Class Info -->
section.
Style the text using CSS so that your name and student id are displayed in the same color (not black or white), and the course title and assignment title are italicized but not bold. Your name and student id should be on the left side of the page while the course title and assignment title should be on the right side of the page and the text aligned to the right. Add a rectangle (or rounded rectangle) around your name and student id. You must do this using CSS; do not use any HTML attributes except id and class!
class
attribute or cascading to reduce the number of rulesborder
and padding
properties will be useful for outlining a region.font-weight
).In the same web page, create an SVG graphic that displays a house using SVG. Your graphic should have the frame of the house, a sloped roof, at least one window, and a door with a circular door knob. The window, door, and roof must have a different color from the rest of the house frame, and the door knob must be a different color than the door. Finally, write CSS so that when the mouse is hovering over the door, the door changes color. Other than that, you may choose to customize your house as you see fit.
You may only use SVG lines, polylines, rectangles, circles, polygons, or paths. You should draw all content in a single svg element. For example,
:hover
psuedo-class will be useful for changing the door’s color