Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Having trouble with this question, file structure, how many files I should have and the content in them. I'm able to create the index.html and

Having trouble with this question, file structure, how many files I should have and the content in them. I'm able to create the index.html and menu.html file, but the javajam.css file is not working for me that I created.

Book - Web Development & Design Foundations with HTML 5

JavaJam Coffee House

See Chapter 2 for an introduction to the JavaJam Coffee House Case Study. Figure 2.31shows a site map for the JavaJam website. The Home page and Menu page were created in Chapter 2. You will develop a new version of the website that uses an external style sheet to configure text and color. Figure 2.32 depicts the wireframe page layout.

You have the following tasks:

Create a new folder for this JavaJam case study.

Create an external style sheet named javajam.css that configures the color and text for the JavaJam website.

Modify the Home page to utilize an external style sheet to configure colors and fonts. The new Home page and color swatches are shown in Figure 3.29.

Figure 3.29

image text in transcribed

New JavaJam index.html

Figure 3.29 Full Alternative Text

Modify the Menu page to be consistent with the new Home page.

Configure centered page layout.

Hands-On Practice Case

TASK 1: THE WEBSITE FOLDER.Create a folder on your hard drive or portable storage device called javajamcss. Copy all the files from your Chapter 2 javajam folder into the javajamcss folder.

TASK 2: THE EXTERNAL STYLE SHEET.You will use a text editor to create an external style sheet named javajam.css. Code the CSS to configure the following:

Global styles for the document (use the body element selector) with background color #FCEBB6; text color #221811; and Verdana, Arial, or any sans-serif font.

Styles for the header element selector that configure background color #D2B48C centered text.

Styles for the h1 element selector that configure 200% line height.

Styles for the nav element selector that configure centered, bold text. Hint: Use the CSS text-align and font-weight properties.

Styles for the footer element selector that configure background color #D2B48C, small font size (.60em), italics, and centered text.

Save the file as javajam.css in the javajamcss folder. Check your syntax with the CSS validator (http://jigsaw.w3.org/css-validator). Correct and retest if necessary.

TASK 3: THE HOME PAGE.Launch a text editor, and open the index.html file. You will modify this file to apply styles from the javajam.css external style sheet as follows:

Add a element to associate the web page with the javajam.css external style sheet file.

Configure the navigation area. Remove the elements which are no longer needed because you have configured bold text with CSS.

Configure the page footer area. Remove the and elementsthey are no longer needed since CSS is now used to configure the text.

Save the index.html file, and test it in a browser. Your page should look similar to the one shown in Figure 3.29 except that your page content will be left-aligned instead of centered. Dont worryyoull center your page layout in Task 5 of this case study.

TASK 4: THE MENU PAGE.Launch a text editor, and open the menu.html file. You will modify this file in a similar manner as you modified the home page: Add the element and configure the navigation and page footer areas. Save and test your new menu.html page. It should look similar to the one shown in Figure 3.30, except for the alignment.

Figure 3.30

image text in transcribed

New menu.html page

Figure 3.30 Full Alternative Text

TASK 5: CENTER PAGE LAYOUT WITH CSS.Modify javajam.css, index.html, and menu.html to configure page content that is centered with 80% width (refer to Hands-On Practice 3.9 if necessary):

Launch a text editor, and open the javajam.css file. Add a style rule for an id named wrapper with width set to 80%, margin-right set to auto, and margin-left set to auto.

Launch a text editor, and open the index.html file. Add the HTML code to configure a div element assigned to the id wrapper that wraps, or contains, the code within the body section. Save and test your index.html page in a browser and youll notice that the page content is now centered within the browser viewport as shown in Figure 3.29.

Launch a text editor, and open the menu.html file. Add the HTML code to configure a div element assigned to the id wrapper that wraps, or contains, the code within the body section. Save and test your menu.html page in a browser and youll notice that the page content is now centered within the browser viewport as shown in Figure 3.30.

Experiment with modifying the javajam.css file. Change the page background color, the font family, and so on. Test your pages in a browser. Isnt it amazing how a change in a single file can affect multiple files when external style sheets are used?

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Securing SQL Server Protecting Your Database From Attackers

Authors: Denny Cherry

2nd Edition

1597499471, 978-1597499477

Students also viewed these Databases questions