08 Homework

Homework for the Final

prepare a pitch of your final website in a new worksheet dedicated to the final.

  1. Introduce the idea.
  2. What are you selling?
  3. This is the problem your website has to solve?
  4. How will the website solve the problem?
  5. Is the proposal sound?
  6. How it is different from other, similar websites?
  7. How does it addresses the target audience?
  8. Write down the problem you are solving and how the website will solve the problem. Include websites of similar products or competing products that helped you form your decision as to how to proceed in the work-sheet, as I will compare the pitch to the final website.
  9. You are allowed to change the problem and how you plan on solving it as time goes on. Add this to the worksheet, as this is to track your creative process.

Homework for the Unit

  1. You are to make your portfolio responsive.
  2. It is up to you to finish it.
  3. I want to see the core pages responsive to one media query, targeting small screens like the iphone.

08 Responsive Web Design

Week 8
10/22

Responsive Design. The web is on display on iPhone and iPad screens to desktop computers. CSS media queries allow you to target each of these devices in one style sheet. Activity: Use media queries to target different devices.

Homework

1) For the class: Redesign the midterm to be responsive to each of these devices. 2) For the final: Develop a proposal for your final project. Read chapter 12. Due: The following week.

Materials

Additional materials for this unit can be found by following these links:

Goals

The goals of this unit are to:

  • Incorporate media queries into web design.
  • To design around the challenges that media queries create when layout out a page across dissimilar devices.

Outcomes

At the end of this unit, students will have:

  • Been prepared for a much more expansive web of the future
  • Incorporated media queries as the basis for future-proofing their own designs.
  • used the various layout strategies that CSS offers in conjunction with media queries.
  • Applied these skills to their Portfolio site.

Step-by-Step

15 Review homework and answer questions.
40 media queries
20 practice: media queries
10 break
70 Hands on in class: making the portfolio responsive

Talking Points

Topics covered in the reading:

Chapter 12: Style Sheets for Mobile to Desktop

  1. Mobile Strategies and Considerations 328
  2. Understanding and Implementing Media Queries 333
  3. Building a Page that Adapts with Media Queries 340

Current Practices

Responsive Web Design is all over the web. In its short existence, no big site has not been redesigned to take advantage of it, and many do it very well:

  • 39 Box Shadows for Chrome
  • This Is Responsive
  • Mule Design Holiday Party
  • Conservation Community
  • Caava Design
  • Dangers of Fracking
  • Frank Chimero
  • Blood, the Branding Agency
  • Women and Tech
  • Jeremy Holmes Studio
  • Adobe HTML
  • Disney
  • Edita’s Casting
  • Rich Brown
  • Etch

    News and External Resources

    Inspirational Links to help you explore in preparation for the final.

    1. Smashing Magazine’s Mobile Content Strategy article.
    2. Google’s Friendly Mobile Test. Does your site pass?
    3. Google’s Page Speed Test. This test (and recommendations on how to fix the problems) are a great way to make sure your site is as good as it can be.

    Definitions

    These are the terms that participants should be familiar with during this unit:

    Responsive Web Design article from Wikipedia

    Responsive Web Design (RWD) is an approach to web design in which a site is crafted to provide an optimal viewing experience—easy reading and navigation with a minimum of resizing, panning, and scrolling—across a wide range of devices (from desktop computer monitors to mobile phones).[1][2][3]

    Elements of Responsive Web Design

    A site designed with RWD[1][4] uses CSS3 media queries[3][5][6], an extension of the @media rule[7], to adapt the layout to the viewing environment—along with fluid proportion-based grids[8] and flexible images:[9][10][11].

    • Media queries allow the page to use different CSS style rules based on characteristics of the device the site is being displayed on, most commonly the width of the browser.
    • The fluid grid concept calls for page element sizing to be in relative units like percentages or EMs, rather than absolute units like pixels or points.[8]
    • Flexible images are also sized in relative units, such as to prevent them from displaying outside their containing element.[9]

    Related Concepts

    Progressive Enhancement vs. Graceful Degradation

    Progressive Enhancement” and “Graceful Degradation” (strategies for when a new site design is being considered) are related concepts that predated RWD: scripting (and required host features) are never a given and some browsers of basic or older mobile phones do not understand media queries, so the recommended practice has always been to create a basic web site and then enhance it—rather than try “graceful degradation” to make a complex, heavy site work for the most basic browsers.[12][13][14][15].

    Confusion and Issues with Unobtrusive JavaScript

    Though, in general and particularly with regard to scripting as style sheets are inherently graceful in their degradation, progressive enhancement is preferred over graceful degradation, the strategies are not mutually exclusive. The term “Unobtrusive JavaScript” describes the use of progressive enhancement for all occasions (for example, intrinsic event handler attributes are seen as “obtrusive”), but many contexts (particularly mobile where scripted enhancements must be simple and lightweight and need to initialize quickly) call for an intelligent mix of the two. Some operations (e.g. attaching a load listener) may not need to be “unobtrusive” and may be made more slower and more complicated for no good reason.

    Browser Sniffing vs. Feature Detection

    Browser detection and mobile device detection are completely unreliable (see Browser sniffing) ways to determine whether Javascript and certain HTML and CSS features are supported [16]. Feature detection and testing are the preferred methods and such cross-browser scripting techniques can be used to effect progressive enhancement. A JavaScript library is not required to use, and may in fact inhibit, feature detection and testing. The typical library attempts to detect (and correct as they see it) a wide range of features, adding enough additional script to render other time and space-saving measures moot (i.e. documents can end up taking longer to download and initialize, despite original good intentions).

    “Mobile First” Layout and Alternatives

    “Mobile First” refers to layouts that are optimized for very small screens (which is unlikely to be optimal for most mobile devices in use today) and then enhanced for larger screens with media queries (and sometimes scripting). Traditionally, Websites have been written for the desktop first and then slimmed down for smaller screens. The reasons for this include the standard “handheld” media type, which is used to override rules that are less than ideal (e.g. large background graphics, multi-column layouts) for very small screens. Media queries came several years later and are not supported by IE 8 and under.

    Conditional Comments

    Conditional Comments may be used to turn “Mobile First” layouts into something more appropriate for legacy IE versions and modes (8 and under and equivalent compatibility modes). This is far preferable to trying to simulate media queries with script as layout should not rely on scripting (or the features required for such a simulation). However, there is a problem with this approach as non-IE browsers that do not support media queries will render the “mobile” layout.

    Example:

    
    <link type="text/css" rel="stylesheet" href="/css/handheld.css" media="all">
    
    <!--[if lt IE 9]>
    
    <link rel="stylesheet" type="text/css" href="/css/desktop.css" media="screen">
    
    <![endif]-->
    
    <link type="text/css" rel="stylesheet" href="/css/desktop.css" media="screen and (min-device-width:40em)">
    
    

    Handheld Media Type

    Many older and lesser mobile devices do not support media queries, but a significant number support “handheld” media style sheets (and have since the early part of the century), which eliminates the need to design for “Mobile First” and then add additional CSS for legacy IE versions.

    Example:

    
    <link type="text/css" rel="stylesheet" href="/css/desktop.css" media="all">
    
    <link type="text/css" rel="stylesheet" href="/css/handheld.css" media="screen and (max-device-width:40em)">
    
    <link type="text/css" rel="stylesheet" media="handheld" href="/css/handheld.css">
    
    

    Challenges, and Other Approaches

    Luke Wroblewski has summarized some of the RWD and mobile design challenges, and created a catalog of multi-device layout patterns.[17][18][19][20] He suggests that, compared with a simple RWD approach, Device Experience or RESS (Responsive Web Design with Server Side Components) approaches can provide a user experience that is better optimized for mobile devices.[19] Server-side implementation of dynamic stylesheet languages like Sass can be part of such an approach. Unfortunately, such techniques are hobbled by server-side browser sniffing.

    One problem for RWD is that banner advertisements and videos are not fluid.[21] However search advertising and (banner) display advertising support specific device platform targeting and different advertisement size formats for desktop, smartphone, and basic mobile devices. Different landing page URLs can be used for different platforms,[22] or Javascript can be used to display different ad variants on a page.[23][18] Unfortunately, this approach requires browser sniffing at some point.

    History

    Ethan Marcotte coined the term Responsive Web Design (RWD) in his article in A List Apart.[1] He describes the theory and practice of responsive web design in his brief 2011 book on the subject.[24] Responsive Design was listed as #2 in Top Web Design Trends for 2012 by .net magazine[25] (Progressive Enhancement was #1). They also listed 20 of Ethan Marcotte’s favorite responsive sites.[2]

    External links

    References

    1. ^ a b c Marcotte, Ethan (May 25, 2010). “Responsive Web Design”. A List Apart. http://www.alistapart.com/articles/responsive-web-design/. 
    2. ^ a b “Ethan Marcotte’s 20 favourite responsive sites”. .net magazine. October 11, 2011. http://www.netmagazine.com/features/ethan-marcottes-20-favourite-responsive-sites. 
    3. ^ a b Gillenwater, Zoe Mickley (Dec. 15, 2010). “Examples of flexible layouts with CSS3 media queries”. http://zomigi.com/blog/examples-of-flexible-layouts-with-css3-media-queries/. 
    4. ^ Pettit, Zoe Nick (Aug. 8, 2012). “Beginner’s Guide to Responsive Web Design”. TeamTreehouse.com blog. http://teamtreehouse.com/blog/beginners-guide-to-responsive-web-design. 
    5. ^ Gillenwater, Zoe Mickley (Oct. 21, 2011). “Crafting quality media queries”. http://zomigi.com/blog/essential-considerations-for-crafting-quality-media-queries/. 
    6. ^ “Responsive design—harnessing the power of media queries”. Google Webmaster Central. Apr. 30, 2012. http://googlewebmastercentral.blogspot.jp/2012/04/responsive-design-harnessing-power-of.html. 
    7. ^ W3C @media rule
    8. ^ a b Marcotte, Ethan (March 3, 2009). “Fluid Grids”. A List Apart. http://www.alistapart.com/articles/fluidgrids/. 
    9. ^ a b Marcotte, Ethan (June 7, 2011). “Fluid images”. A List Apart. http://www.alistapart.com/articles/fluid-images/. 
    10. ^ “Adaptive Images”. http://adaptive-images.com/. 
    11. ^ Jacobs, Denise (August 23, 2011). “21 top tools for responsive web design”. .net Magazine. http://www.netmagazine.com/features/21-top-tools-responsive-web-design. 
    12. ^ Wroblewski, Luke (November 3, 2009). “Mobile First”. http://www.lukew.com/ff/entry.asp?933. 
    13. ^ Firtman, Maximiliano (July 30, 2010). Programming the Mobile Web. ISBN 978-0-596-80778-8. 
    14. ^ “Graceful degradation versus progressive enhancement”. February 3, 2009. http://dev.opera.com/articles/view/graceful-degradation-progressive-enhancement/. 
    15. ^ Designing with Progressive Enhancement. March 1, 2010. ISBN 978-0-321-65888-3. 
    16. ^ http://jibbering.com/faq/notes/detect-browser/
    17. ^ Wroblewski, Luke (May 17, 2011). “Mobilism: jQuery Mobile”. http://www.lukew.com/ff/entry.asp?1330. 
    18. ^ a b Wroblewski, Luke (February 6, 2012). “Rolling Up Our Responsive Sleeves”. http://www.lukew.com/ff/entry.asp?1494. 
    19. ^ a b Wroblewski, Luke (February 29, 2012). “Responsive Design … or RESS”. http://www.lukew.com/ff/entry.asp?1509. 
    20. ^ Wroblewski, Luke (March 14, 2012). “Multi-Device Layout Patterns”. http://www.lukew.com/ff/entry.asp?1514. 
    21. ^ Snyder, Matthew; Koren, Etai (Apr. 30, 2012). “The state of responsive advertising: the publishers’ perspective”. .net Magazine. http://www.netmagazine.com/features/state-responsive-advertising-publishers-perspective. 
    22. ^ Google AdWords Targeting (Device Platform Targeting)
    23. ^ JavaScript and Responsive Web Design Google Developers
    24. ^ Marcotte, Ethan (2011). Responsive Web Design. p. 143. ISBN 978-0-9844425-7-7. http://www.abookapart.com/products/responsive-web-design. 
    25. ^ “15 top web design and development trends for 2012”. .net magazine. January 9, 2012. http://www.netmagazine.com/features/15-top-web-design-and-development-trends-2012. 
  • 08 Media Queries

    The future of the web is not necessarily tied to the browser window that you have been using. Chances are that it’ll be mobile. Spanning screens from large to small requires a complete separation between content and form, so that the content can be rearranged to fit the different viewports.

    Designing for the Future

    Your web content will run everywhere and on everything. The future means to take into account that the web has gone global.

    Different devices and markets will all be using this language for all kinds of purposes. Nor does it need to be displayed on a browser. Web services like Facebook, Twitter and the like have taken over a big chunk of the web, and they can bypass the browser, even if they use the same display technology.

    Scalable and Adaptive Designs

    The task of the designer is to provide a consistent user experience across all these possible media. You need to see that the core information of the website remains accessible no matter what the device or how disparate the user and the screen needs to look as if you designed it on a 1920×1080 monitor or a 320×240 pixel mobile screen, for use with a mouse, remote control or a stubby finger.

    Rethink Your World

    A stubby finger is a lot different to design for than a mouse driven computer monitor. What does the User Experience look like to your fingers? Apply had to greatly simplify the interface to adapt it to the ends of your fingers. Take another look at Apple’s Best Practices for mobile devices.

    Simplify the Core, Make it Adaptable

    It is better to start with the simple requirements of the mobile web site and then build your website for larger viewports. The default works on mobile platforms, and you use @media queries to adapt to larger viewports.

    Different viewports require different things from a user, and what that is changes with the size and use of the device. Using a website on an iPhone while walking down the street is a lot different than cruising web sites at home on your computer.

    There are no single solutions that solve all problems. If there are no clear answers, it is because all of this is still new. Give a few years to settle down.

    Media Types

    In CSS2.1, @media types are used to target different media, like screen, print all and some others that you have probably never seen. What you do see is a media attributed in the link tag that connects the document to the external stylesheet: media="screen" or media="all".

    It is possible to target the different @media rules within the same style sheet, allowing exceptions between print and screen in one stylesheet. For example:

     @media print {
        body { font-size: 10pt }
      }
      @media screen {
        body { font-size: 13px }
      }
      @media screen, print {
        body { line-height: 1.2 }
      }
    

    Media Queries

    CSS3 added @media queries, implemented along the lines of media types. Media queries allow the physical characteristics of the media determine how the CSS layout is rendered. The presentation of the media adapts to different devices without a change in the content.

    A media query consists of a media type and zero or more expressions that check for the conditions of particular media features like height, width, color.

    The width or height of the viewport then triggers the media query to switch the styles in real time when the viewport width or height goes above or below a certain threshold, or if the orientation of the device changes from horizontal to vertical.

    This example is set to toggle between the portrait and landscape orientations:

      /* Portrait */
    @media screen and (orientation:portrait) {
        /* Portrait styles */
    }
    /* Landscape */
    @media screen and (orientation:landscape) {
        /* Landscape styles */
    }
    

    How Media Queries Work

    You may query as many media as you like, using basic Boolean operators to determine the logic of each query. Use “and” to specify in addition to and “,” to specify or, as in this example @media all and (min-width: 700px) and (max-width: 900px), (orientation:landscape) , which reads, for all media, the minimum width is 700px and the maximum width is 900 pixels, or the orientation is landscape. You can also use negation by writing out the word “not”.

    When using and, both parts have to be true to activate the media query. If using or (“,”) the media query is true if any one part is true. This is how boolean logic works.

    Like media styles, media queries can be used to change the style sheet, or to change the style in a single stylesheet.

    Changing Stylesheets

    The following example has the media determine the link used to present the HTML: example (download example) Changing the window triggers three style sheets: “narrow.css” determines the style when the viewport is below 700 pixels, “medium.css” determines the style when the viewport is between 701 to 900 pixels and the “wide.css” determines the style when the viewport goes wider than 900 pixels.

    The three stylesheets are switched in real time as the window is resized, as you can see in the example.

    <link rel='stylesheet' media='screen and (max-width: 700px)'
    href='narrow.css' />
    <link rel='stylesheet' media='screen and (min-width: 701px)
    and (max-width: 900px)' href='medium.css' />
    <link rel='stylesheet' media='screen and (min-width: 901px)'
    href='wide.css' />
    

    Changing Styles within a Stylesheet

    The more common approach is to use media queries within a single style sheet.

    The @media rule comes first, an opening bracket, the css rules to be affected and a closing bracket:

    @media all and (min-width: 701px) and (max-width: 900px) {
    section{width: 480px;}
    article {width: 480px; background-color: red;}
    }

    The example demonstrates the integration of media queries within the stylesheet itself. The styles are usually placed at the bottom of the CSS style sheet. That can make the style sheet significantly longer.

    To keep scrolling to a minimum while writing the CSS, it is recommended to write the rules right after the selectors, one property after the other, rather than having each property take up its own line. Use Clean CSS to reformat and clean up your CSS so that all the properties are inline. The settings to use are High (moderate readability, smaller size) and Preserve CSS.

    Locking Down the Viewport and Zoom

    The iPhone will assume a viewport of 980 pixels and zoom it to fit the screen resolution by default, unless you tell it not to. This requires that you put the following into the header:

    <!- This sets the viewport to the device (iPhone) screen size, and forces the zoom to be 1:1
    ----------------------------------------------- -->
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    

    Building Future Proof Web Sites

    You need to be future-proofing your websites by using the @media queries from the ground up. The fundamental structure of the layout needs to be developed with these different devices in mind, and built so that its design remains consistent when accommodating these devices.

    Best practices requires all of possible media are considered at the outset, and to develop all of them at the same time. This is a radical change from the general procedure of a previous era, in which one style sheet was amended after the fact to work on different browsers. The world has changed, the future looks different, and this is how we adapt.

    How to Proceed

    Key is to design for older browsers in the default space. They do not read the styles inside of the media query blocks, and will function just fine, so the site will be backward compatible.

    Then use media queries to target device / viewport width, starting with the smallest, and progressively work up to the largest, with each iteration of the media queries overwriting the previous one.

    Revisit the boilerplate, and you will see that it is set up for media queries, and everything you have done up to now targets the older browsers.

    Each property has to override the property set up before it, if you want that property to change. This can be tricky, but once you see how it works, you will have mastered using @media queries.

    Prioritize each element in your design. Figure out how each element needs to adapt to the different devices.

    Develop a strategy, and draw it out using the following Responsive Design Sketch Sheetsby Jeremy Palford. I want to see you use them for the final. Post them in your worksheet. Not just one. Many! I want to see your work out your design problems.

    JumpStart the Future

    Smashing Magazine has good articles, and there tools to help you, including a preview of what a device size looks like with Resize my browser window, and a responsive, a way to see your project in all widths at once.

    Even better is a bookmarklet that you can set up, and once clicked, will automatically provide however many special widths you have set up. This is a great solution to simulate all the device widths, as long as you remember to check actual devices to make sure that what you see is what you get.

    Be the Future

    The path that we will take is the one we already have taken. The HTML5 boilerplate already has a place all ready for @media Queries in the CSS stylesheet:

    /* ==========================================================================
       EXAMPLE Media Queries for Responsive Design.
       Theses examples override the primary ('mobile first') styles.
       Modify as content requires.
       ========================================================================== */
    
    @media only screen and (min-width: 35em) {
        /* Style adjustments for viewports that meet the condition */
    }
    
    @media only screen and (-webkit-min-device-pixel-ratio: 1.5),
           only screen and (min-resolution: 144dpi) {
        /* Style adjustments for high resolution devices */
    }
    

    This is where you will create your media queries. We will practice doing media queries the next two weeks as we explore additional CSS3 properties.

    More Information

    Read the Responsible Web Design article with before, and after examples if you want more information.

    A complete list of the different queries that can be addressed from devices (In case you thought that width and height were the only ones). Device means the rendering surface of the device, otherwise it means the display area, like the browser’s window or viewport.

    • width
    • height
    • device-width
    • device-height
    • orientation (portrait or landscape)
    • aspect-ratio
    • device-aspect-ratio
    • color (how many colors the device is capable of)
    • color-index
    • monochrome
    • resolution (including retina display)
    • scan
    • grid

    08 Responsive Design

    Responsive design started with the May 25, 2010 article Responsive Web Design by Ethan Marcotte discussing media queries. Flexible layouts and responsive images are two additional ingredients required for responsive web design to work.

    Flexible Layouts

    I have discouraged you from using percent in specifying your measurements. They are a cause for confusion when first starting out. That time has passed, and we can begin to think of a completely new and flexible way to laying out websites.

    Responsive means to respond to the conditions, instead of being rigid and fixed. To be rigid and fixed means specifying everything in terms of pixel measurements. That way the layout does not move, no matter what.

    The first think one can do to bring in some level of flexibility is to size everything to a central scalable unit. When that unit changes, everything changes accordingly. This happens when using the em as a relative unit of measurement.

    An em is a unit of measurement in the field of typography, equal to the currently specified point size. The unit was originally derived from the width of the capital “M” in a given typeface. These days it stands for the height of a font. This unit is the same for all fonts at a given point size. For example, 1em in a 16 point typeface is 16 points, the default size for browsers.

    CSS allows one to measure everything in em units, and it is best practices to do so. You set the size of the em in the body tag when you define the size of the text. Ifbody {font-size: 16px;}, it would be the same as the default size of the browser, and unless a user changed that default, it would not make a difference.

    Now imagine if everything in the entire document were specified in em values. If div {width: 20em; height: 10em; padding: .25 em That would make the box 328 pixels wide and 168 pixels high because of the added 4px padding, as long as the em is defined as 16 pixels in the body. Change that, and the entire layout would increase or decrease, but all the elements would remain proportional, that is, the look would be maintained no mater what the size.

    This is easier said than done, and now that browsers automatically keep documents proportional as they resize them, it is no longer necessary. That said, it is still a good idea to tie all of your font sizes to a central em size determined in the body of the document.

    Because percentages are often used to resize fonts, it is possible to add percentages on top of percentages. When the font size of both a child and its parent are set at 80%, the child ends up being 80% of 80% of the em. To avoid that, CSS3 introduced a rem, which stands for reference em. Unlike the em, the rem is not affected by inheritance.

    To calculate the size of a headline: divide the desired size by the reference em or rem. The same formula target ÷ context = result is used to figure out the correct percentages in fluid layouts.

    Fluid Layouts

    Fluid layouts expand and contract with the size of the window or viewport. Instead of using pixels or ems, a percentage of the parent element is used. This width is applied to the elements floated to the right or left that make up the layout. This example starts with a pixel based layout and converts it to a percentage based layout.

    column diagram from Marcotte's Responsive Web Design book
    visit the website

    A 960 pixel wide web page is more or less standard these days. That 960 pixel wrapper div can be divided up into a grid of 12 columns, each measuring 69 pixels across and separated by regular 12px-wide gutters. Taken together, those columns and gutters give us a total width of 960 pixels.

    If the main article were 6 grid columns, and the side column were three grid columns, with a column between them, that would fit in a container 900 pixel wide, leaving around a half column on either side. If we were to break this into pixel width, the main column width would be 566p pixels and the side column would be 331 pixels wide. See illustration above.

    A fluid grid is proportional to the window, or viewport. Assuming that the viewport is 100%, give the wrapper div a little padding on either side, and instead of 960pixels, make it 90%. That is 90% of the body tag, or 90 % of the window size. Once we have that width of the page established, we use it to define all other widths.

    Figuring out the percentage of a 900px container in a 960px page, plug it into the formula target ÷ context = result, dividing 900 ÷ 960 = 0.9375. That makes the container that holds the two columns 93.75% of the page size.

    The two columns fit inside of a 900 pixel container, and when the width of the column is divided by that results in two more values that can be used, or 62.8888889% for the large column and 36.7777778% for the small column. Do not round the numbers off, as the layout will be more accurate if you keep that information.

    There is a lot more to do in the layout, to translate all of the padding and margins to percentages, but you now understand how to apply the formula target ÷ context = result, dividing the child into its parent to get the right percentage.

    The fluid layout will always be 90% of the window size. The layout will be problematic when the window becomes too small or large. Use min-width and max-width to keep it from doing that. This would be where media queries come in handy.

    Flexible Margins, Padding, Text Formatting and Images

    Everything needs to be flexible. The padding and margins that need to be flexible, the text formatting needs to be flexible and the images need to be flexible, All of them need to be written in percentages of their parent’s width, so they can resize along with the fluid width of the columns.

    This is accomplished easily enough. Just set the image width to a percentage of the parent element, and it will resize along with it. Background images too, can be set in that way, or can be tiled or can be cropped.

    That is easy. Now you have the ingredients of creating a fluid based web site. Aren’t you happy I didn’t try to explain this when you were first learning about how to layout a web page?