60 likes | 177 Vues
This week's focus is on understanding the fundamentals of HTML (HyperText Markup Language) and JavaScript, essential tools for web design. HTML allows you to create structured web pages with links and multimedia elements, interpreted by browsers. You'll explore common HTML tags for headings, paragraphs, lists, and images, and learn about JavaScript, which adds interactivity to webpages. By the end of this week, you should be comfortable creating simple web pages and using basic JavaScript for dynamic content.
E N D
CS 111 – Oct. 4 • Web design • HTML • Javascript • Commitment: • This week, read sections 4.3 – 4.5.
HTML • Stands for: HyperText Markup Language • Hypertext means a text document that contains links to other documents • Also may contain multimedia. • HTML is interpreted by a browser • .html file contains content as well as formatting and layout commands • Dreamweaver can hide these details from you
HTML (2) • File format <html> <head> … </head> <body> … </body> </html> • Head section is optional • Body contains material to appear in browser window. • What does simplest Web page look like?
Common tags • h1, h2, etc. = headings • br = line break • p = paragraph • b, i = font should be bold or italic • hr = horizontal rule • ol,ul, li = used for lists • sub, sup = subscript or superscript • <img src=“name-of-image.gif”> • <a href=“name of file or URL”> text to underline </a>
Javascript • Can write simple programs with little or no prior experience • Purpose of JS is to give some interactive “life” to Web pages. • Works with a Web browser. • First, create HTML file using editor or Dreamweaver. • Refresh the browser when you make a change. • Online guide for general reference • http://www.w3schools.com/js/js_examples.asp • We’re only going to scratch the surface
Simple JS features • Printing a message • Using variables • Looking up the time • Making choices • Doing something several times (a loop) • A form inside HTML • Can create form object in Dreamweaver. • In Javascript, write instructions on how to handle the input.