VJC Chapter 7 HTML and CSS
Uploaded by cheesemuffin · 10 December 2025
Preview
Chapter 7: HTML and CSS Contents 1 HTML Document 2 Adding elements 3 HTML form 4 CSS 4.1 Inline CSS 4.2 Internal CSS 4.3 External CSS 4.3.1 Using element selector 4.3.2 Using id Selector 4.3.3 Using class Selector Syllabus Learning Outcomes 4.2 Web Applications Understand the concepts and techniques for developing web applications. 4.2.3 Use HTML, CSS (for clients) and Python (for the server) to create a web application that is able to: – accept user input (text and image file uploads) – process the input on the local server – store and retrieve data using an SQL database – display the output (as formatted text/images/table).
1 HTML Document Every Hypertext Markup Language (HTML) document you create or load is derived from this basic template: This template can be broken down into 4 parts: DOCTYPE : An HTML document will usually start with a type declaration (which is not a tag, so it should not have a closing tag). The declaration helps the browser determine what type of HTML document it’s trying to parse and display. Browsers look for this doctype declaration to determine which rendering mode to use to render the site <html> : Represents the root (top-level element) of an HTML document, so it is also referred to as the root element. All other elements must be descendants of this element. <head> : Describes meta information about the site, such as the title, and provides links to scripts and stylesheets the site needs to render and behave correctly. For instance, the <head> is responsible for: ● the document’s title (the text that shows up in browser tabs): o <title>About Me</title>. ● associated CSS files (for style): o <link rel="stylesheet" type="text/css" href="style.css">. ● associated JavaScript files (multipurpose scripts to change rendering and behavior): o <script src="animations.js"></script>. ● the charset being used (the text's encoding): o <meta charset="utf-8">. ● keywords, authors, and descriptions: o <meta name="description" content="This is what my website is all about!">. ● … and more!
At this point, just focus on these two tags: ● <title>About Me</title> ● <meta charset="utf-8"> <meta charset="utf-8"> is pretty standard, and will allow your website to display any Unicode character. <title> will define the title of the document and will be displayed in the tab of the browser window when a user visits the page. <body> : Describes the actual content of the site that users will see (always visible). Basic HTML tree
Content continues in the PDF.
Related notes
- VJC Chapter 21 SQLite with PythonNotes/Practices · 2025
- VJC Chapter 23 Web Applications PrinciplesNotes/Practices · 2025
- VJC Chapter 10 RecursionNotes/Practices · 2025
- VJC Chapter 20 SQLNotes/Practices · 2025
- VJC Chapter 16 Hash TableNotes/Practices · 2025
- VJC Chapter 22 NoSQLNotes/Practices · 2025

